This is a simple PHP CRUD API that allows you to perform basic CRUD operations on a MySQL database.
- PHP 7.4 or later
- MySQL 5.7 or later
- WebServer : mamp , xammp
- Clone the repository
git clone https://github.com/your-username/php-crud-api.git
The API is accessible at http://localhost:8000/api
. You can use the following endpoints to perform CRUD operations:
GET /api/catagory
- Get all categoriesPOST /api/catagory
- Create a new categoryGET /api/catagory/{id}
- Get a single category by IDPUT /api/catagory/{id}
- Update a category by IDDELETE /api/catagory/{id}
- Delete a category by ID
Contributions are welcome! Please submit a pull request if you have any improvements or suggestions.
This project is licensed under the MIT license.