This project implements a basic web server in Python that handles GET and POST requests. It serves a custom HTML page and responds to form submissions with personalized messages.
- Serves a static HTML page (
index.html). - Handles
POSTrequests to personalize responses. - Displays a simple greeting based on user input.
- Python 3.x installed on your machine.
-
Clone this repository:
git clone https://github.com/yourusername/simple-web-server.git cd simple-web-server -
Run the server:
python server.py
-
Open your browser and navigate to
http://localhost:8000.
- The server serves
index.htmlfor GET requests. - For
POSTrequests, it extracts form data and responds with a personalized message.
server.py: The main server script.index.html: The HTML page served by the server.