I need a system that will automatically populate a list of currencies and then update each currency with the current exchange rate and timestamp of that exchange rate. This should use [login to view URL] for real life currencies and it should use [login to view URL] for second life Linden Dollars.
Database tables need to be updated regularly to keep a list of all available currencies up to date and similiarly the rate of convertion between a base currency which must be user definable with a time stamp for when each convertion rate was saved is needed. This must be unix time stamps stored as int data type in a database (See php time() ).
The system should be 100% automated, using a php script called from a cron jobs. It should also allow for manual update by clicking a button / link.
A php class is required. All functionality must be encapsulated within this class as functions. It should also provide convertion methods for currencies. This must allow for time based convertions. For example the convertion between £ and $ on the 21/06/09 should use the rate recorded for that date. Similiarly if a cost of £100 is to be converted over 3 days then each day must use the convertion rate recorded for it (or use multiple rates if more than 1 is recorded per day).
All information stored within the database must be listed on html pages. This includes but is not limited to all available currencies as well as a listing for each currency and its convertion rate as a historical view, a edit page to set the base currency to which all others are converted by default is also required as well as an option to set "Enabled" on a currecy so that only the ones in use are updated. This should be plain and basic html - it just has to work.
The database should record the currency convertion rate to GBP, the Symbol for the currency (e.g. £, $, etc) and the code for the currency (e.g. GBP, USD, etc)