soswebapp is a web application designed to facilitate the search for student details using their admission number. The application uses Python with the Flask framework and a MySQL database to store student information.
- Search for student details using admission number.
- Display student details including name and contact numbers.
- Call functionality directly from the web interface.
The main files in the repository are:
app.py
: The main Flask application file that handles routing and database interactions.templates/index.html
: The HTML template for the search form.templates/result.html
: The HTML template for displaying student details.
To set up and run the soswebapp, follow these steps:
- Clone the repository:
git clone https://github.com/basil-the-py-developer/soswebapp.git cd soswebapp
- Install dependencies:
Make sure you have Python and MySQL installed. Then, install the required Python packages:
pip install flask mysql-connector-python
- Database setup:
Create a MySQL database and update the database configuration in app.py:
CREATE DATABASE school_emergency_sos; USE school_emergency_sos;
- Run the application:
Start the Flask application:
python app.py
- Access the application: Open your web browser and go to http://127.0.0.1:5000/.
- Navigate to the home page.
- Enter the student's admission number in the search form.
- Click the "Search" button to view the student's details.
- If the student is found, their details including name and contact numbers will be displayed.
- Click on the call button to initiate a phone call to the student's contact number.