We have a Webservice running where a user can submit an array of integers (they are stored in our database) and gets a short url-back.
If the user then visits the short url, we access a freely available api, get information to every integer stored before display a list with all integers and the subsequently retrieved information.
Our webservice contains out of 1 MySQL-Database and 4 PHP-files.
Now i need:
- A code-cleanup (functions should be in one external PHP file), a bit of comments
- Cache: A solution to cache the retrived data-set for every integer in the database. So that we would only need to contact the freely available API for Integers we would not have stored by now. The cache should expire every 3 days.
File-based Cache for Images: If we contact the API we get a json-array back with meta-information. Some of these informations are image-Links which we need to display later. So we like to have also a file-based cache solution for the images.
- The integrated Short-URL generator is not case-sensitive by now. it need to be.