Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/alextkdev/myflaskproject
This project is a blog developed using Flask. It allows users to view posts, add new entries, and leave comments.
https://github.com/alextkdev/myflaskproject
blog flask orm sqlalchemy
Last synced: 2 days ago
JSON representation
This project is a blog developed using Flask. It allows users to view posts, add new entries, and leave comments.
- Host: GitHub
- URL: https://github.com/alextkdev/myflaskproject
- Owner: AlexTkDev
- Created: 2024-05-01T11:29:57.000Z (9 months ago)
- Default Branch: master
- Last Pushed: 2024-12-13T17:18:52.000Z (about 1 month ago)
- Last Synced: 2024-12-13T18:26:21.517Z (about 1 month ago)
- Topics: blog, flask, orm, sqlalchemy
- Language: HTML
- Homepage:
- Size: 21.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Blog Documentation on Flask
## Project Description
This project is a blog developed using Flask. It allows users to view posts, add new entries, and leave comments.
## Project Structure
```
myblog/
├── instance/
│ ├── __init__.py
│ └── config.py
├── templates/
│ ├── base.html
│ ├── index.html
│ ├── post.html
│ └── new_post.html
├── app.py
├── requirements.txt
└── README.md
```### Directory and File Descriptions
- `instance/`: Configuration files.
- `__init__.py`: Package initialization.
- `config.py`: Application configuration.
- `templates/`: HTML templates.
- `base.html`: Common page structure.
- `index.html`: Home page.
- `post.html`: Post page.
- `new_post.html`: New post page.
- `app.py`: Main application file.
- `requirements.txt`: Project dependencies.## Installation and Running the Project
### Prerequisites
- Python 3.8+
- pip### Cloning the Repository
```bash
git clone https://github.com/AlexTkDev/MyFlaskProject.git
cd myblog
```### Installing Dependencies
```bash
pip install -r requirements.txt
```### Running the Application
```bash
flask run
```The application will be available at [http://127.0.0.1:5000](http://127.0.0.1:5000).
## Using Bootstrap 5
Bootstrap 5 is used for styling the pages, included through `base.html`.
## Application Routes
### Home Page
Route: `/`
Description: Displays all posts.
### Post Page
Route: `/post/`
Description: Displays the selected post.
### New Post
Route: `/new`
Description: Form for adding a new post.
## Conclusion
This project is a simple blog on Flask that can be extended and modified to suit your needs. Flask provides flexibility and ease of development, and using templates and Bootstrap 5 allows for creating modern and responsive interfaces.