Skip to content

ctam91/blogz

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

91 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

blogz

LC101 assignment

Web app using flask. Continuation of build-a-blog.

Entity Analysis

  • A blog is a series of entries
  • Each entry includes a title, body, and user

Requirements

The app must meet several requirements:

  • List all users on homepage
  • List all previous blog entries in reverse-chronological order
  • Users must be signed in before creating a new blog entry
  • Users can log in
  • New users can register
  • Display the individual blog entry after creation
  • Include a menu bar with available commands

User Scenarios

  • User enters a username that is stored in the database with the correct password and is redirected to the /newpost page with their username being stored in a session
  • User enters a username that is stored in the database with an incorrect password and is redirected to the /login page with a message that their password is incorrect
  • User tries to login with a username that is not stored in the database and is redirected to the /login page with a message that this username does not exist

Routes

  • "/" - GET: Display list of all users
  • "/blog" - GET: Display list of all blog posts in reverse-chronological order
  • "/blog?id=id" - GET: Display specific blog entries
  • "/blog?userid=userid" - GET: Display blog entries for specific user
  • "/blog/newpost" - GET & POST: Display form for user to add new post
  • "/login" - GET & POST: Display form for user to log in
  • "/signup" - GET & POST: Display for for user to sign up

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published