Commit graph

9 commits

Author SHA1 Message Date
recanman
2025ef0a91 feat: improve cache, refactor code, add api key support 2024-09-09 22:54:33 -07:00
recanman
01365b4c51 style: keep indent style consistent 2024-09-09 21:18:36 -07:00
061892fa04
feat: improve API error handling & add exchange rate updates
- Switched to using cURL for fetching data from CoinGecko API, with added error handling for failed requests. This reduces the chances of runtime errors and ensures fallback to previous data.
- Implemented periodic updates to exchange rates every 5 seconds in `main.js` to keep the rates current.
- Added OpenGraph meta tags on `index.php` for better social media integration.
- Minor CSS adjustments for better table rendering.
- Moved `import` statements for Bootstrap CSS and JS to the top in `main.js`.
2024-08-08 14:55:47 +02:00
3a32bb2fd5
feat: improve coingecko JSON response handling
Updated to always output JSON in response, ensuring the latest data is provided to the client. Previously, data output was conditional based on the update interval. This change guarantees a more consistent API behavior and better user experience by always serving the current state, even if no recent update occurred.
2024-08-08 09:16:25 +02:00
9a09f86460
feat: dynamically fetch and filter currencies list
Replaced the static list of currencies with a dynamic fetch from the CoinGecko API. Implemented a filter to exclude 'bits' and 'sats' from the fetched currencies. This ensures the currency list is always up-to-date and excludes unsupported currencies.
2024-08-08 09:09:06 +02:00
f475b4ff73
refactor(coingecko.php): streamline currency data update process
Consolidated currency list initialization and improved data fetching from CoinGecko API. Enhanced error handling for CURL requests. Optimized the logic for updating and saving currency data, ensuring more efficient and readable code. Ensured data write-back occurs only when sufficient time has elapsed since the last update.
2024-08-08 08:58:55 +02:00
Luke
fecdf3c231
Update coingecko.php 2024-05-24 11:14:53 +02:00
Luke
dc42ceebd6
Update coingecko.php
Remove old API, code formatted
2023-05-15 09:21:59 +02:00
Luke
9430dfcef9
added full project 2023-05-15 09:04:02 +02:00