A currency converter tool that fetches and displays real-time exchange rates using an external API and allows users to convert amounts between different currencies. Built using PHP, HTML, jQuery, AJAX, JSON, Bootstrap, CSS, and MySQL.
MIT License
A PHP-based Currency Converter tool that allows users to convert currencies using real-time exchange rates fetched from an external API. The tool is built with PHP, HTML, jQuery, AJAX, JSON, Bootstrap, CSS, and MySQL. The application is designed to provide accurate currency conversion and display results in a user-friendly interface.
Topics: php
, mysql
, blog
, ajax
, bootstrap
, jquery
, css
, currency conversion
, external api integration
, api integration
Clone the repository:
git clone https://github.com/yourusername/simple-currency-converter.git
Navigate to the project directory:
cd simple-currency-converter
Set up the database:
image_gallery
.mysql -u yourusername -p currency_converter < db/database.sql
Update the database configuration:
config.sample.php
to config.php
:
cp config.sample.php config.php
config.php
and update the database configuration details.Setup API Integration:
config.php
file with your API key and endpoint details.// API configuration
define('API_URL', 'https://api.exchangerate-api.com/v4/latest/');
define('API_KEY', 'your_api_key_here');
Directory Permission:
chmod 777 assets/uploads
config.php
and update the database configuration details.Start the development server:
php -S localhost:8000
Access the application:
http://localhost:8000
.Heres a basic file structure for your simple-currency-converter application:
simple-currency-converter/
index.html
db/
database.sql
include/
config.sample.php
db.php
assets/
css/
style.css
js/
script.js
src/
fetch-rates.php
convert.php
get-currencies.php
README.md
.gitignore