12.11
php
saved
PhpNut
Note
Application to be developed using PHP framework of choice.
Application to be developed using PHP framework of choice.
- Users can have many posts
- Users can be Admin with control over all other users
- Posts can have many comments
- Comments are threaded
- Posts are tagged
- First page will list random latest post from all users and have a tag cloud on the page, linking to lists of posts related to the tag
- Clicking on the title will take to full post with comments threaded below it
- Clicking on a users name in a post will take you to that users posts list showing all recent posts
- Comments editable by admin only
- Comments are moderated, not moderated of off all together
- Sessions will be used to "authenticate" user
- Users can request access to blog, this will create an account for then active being set to 0 until a user with admin rights turns it on
- Data output from the database, must be sanitized to remove any chars that could be harmful.
- If there is a url in the body or content it needs to be converted to a linked url
- Queries can be cached.
- Models can be cached.
- No view output can be cached (data displayed as html)
- Output will be in HTML and RSS feed
- If database is altered in anyway, these changes must agreed and changed in all installs
- CREATE TABLE comments (
- id INTEGER(10) UNSIGNED NOT NULL AUTO_INCREMENT,
- post_id INTEGER(10) UNSIGNED NOT NULL,
- comment_id INTEGER(10) UNSIGNED NOT NULL,
- published TINYINT(1) NOT NULL,
- title VARCHAR(100) NOT NULL,
- body TEXT NOT NULL,
- username VARCHAR(100) NOT NULL,
- email VARCHAR(255) NOT NULL,
- website VARCHAR(255) NULL,
- created DATETIME NULL,
- modified DATETIME NULL,
- INDEX PUBLISHED_INDEX(published)
- );
- CREATE TABLE posts (
- id INTEGER(10) UNSIGNED NOT NULL AUTO_INCREMENT,
- user_id INTEGER(10) UNSIGNED NOT NULL,
- title VARCHAR(100) NOT NULL,
- content TEXT NOT NULL,
- comments TINYINT(1) NOT NULL,
- moderate TINYINT(1) NOT NULL,
- created DATETIME NULL,
- modified DATETIME NULL,
- );
- CREATE TABLE posts_tags (
- post_id INTEGER(10) UNSIGNED NOT NULL,
- tag_id INTEGER(10) UNSIGNED NOT NULL
- );
- CREATE TABLE tags (
- id INTEGER(10) UNSIGNED NOT NULL AUTO_INCREMENT,
- name VARCHAR(20) NULL,
- keyname VARCHAR(20) NULL,
- created DATETIME NULL,
- modified DATETIME NULL,
- UNIQUE INDEX KEYNAME_UNIQUE_INDEX(keyname)
- );
- CREATE TABLE users (
- id INTEGER(10) UNSIGNED NOT NULL AUTO_INCREMENT,
- actvie TINYINT(1) NOT NULL,
- admin TINYINT(1) NOT NULL,
- username VARCHAR(100) NOT NULL,
- email VARCHAR(255) NOT NULL,
- passwd VARCHAR(45) NOT NULL,
- created DATETIME NULL,
- modified DATETIME NULL,
- UNIQUE INDEX USERNAME_UNIQUE_INDEX(username),
- UNIQUE INDEX EMAIL_UNIQUE_INDEX(email)
- );
Parsed in 0.079 seconds, using GeSHi 1.0.7.14