“Full-stack web app for Energy for Africa, built with Flask, MySQL, SMTP, and deployed on Railway.”
# ⚡ Energy for Africa – Web App (Flask + MySQL)
**Energy for Africa** is a modern web platform built to promote awareness, innovation, and collaboration around sustainable energy solutions across the African continent.
> Built with Flask, MySQL, and deployed via Railway
---
## 🌍 Features
- ✅ Responsive and engaging landing page
- ✅ Dynamic contact form with email + database integration
- ✅ Admin dashboard to view submitted form data
- ✅ Scroll-triggered animations & mobile optimization
- ✅ Rebranded from TotalEnergies to support African energy initiatives
---
## 🚀 Live Demo
🔗 Visit Energy for Africa Live
---
## 💡 Why this Project?
Access to clean, affordable energy remains a major challenge across Africa. This platform:
- Serves as an **informational hub** on energy topics
- Acts as a **call-to-action** for sustainable development
- Demonstrates **full-stack web development** in action
---
## 📦 Tech Stack
| Frontend | Backend | Database | Deployment |
|----------------|---------------|----------|------------|
| HTML, CSS, JS | Flask (Python)| MySQL | Railway |
---
## 🛠️ Setup & Deployment
### 🔗 One-Click Deploy (via Railway)
> Use the button above to clone and deploy this project on Railway instantly.
---
### 🧪 Local Development
```bash
# 1. Clone the repository
git clone
github.com
cd Energy-for-Africa
# 2. Set up a virtual environment
python -m venv venv
# For Windows:
venv\Scripts\activate
# For Mac/Linux:
source venv/bin/activate
# 3. Install required packages
pip install -r requirements.txt
Environment Variables
Create a .env file in the root directory and add the following variables:
env
Copy
Edit
# MySQL Database Configuration
MYSQL_HOST=your_mysql_host
MYSQL_USER=your_mysql_user
MYSQL_PASSWORD=your_mysql_password
MYSQL_DB=your_database_name
# Email SMTP Configuration
MAIL_SERVER=smtp.yourmail.com
MAIL_PORT=587
MAIL_USERNAME=your_email@example.com
MAIL_PASSWORD=your_ …