Project assignment 1. Due Tuesday March 28

General blog description

Your blog will generate data based on the database that stores the following: Your task for the rest of the semester is to design and implement a web site that displays this data and lets users post messages and comment on other people's messages.

The blog design and formatting

The display style of the blog pages must be set using external CSS files. An occasional in-line style is OK, but beware that those can easily get out of hand. You should have at least two different CSS files for your blog.

There are two ways in which you can set a layout of a page: using tables an using CSS formatting features. To start with, you should use tables to format your page. We may cover CSS formatting later in the course, or you can read ahead if you prefer to use that instead of (or in addition to) tables.

Task 1: design the layout and the style of your pages

Think of what pages you need in the blog and what these pages will look like (the layout, the style). The pages that you need at this point are: Your task is to come up with two CSS files for two different styles of your blog. Draw pictures, think of fonts, styles, and colors. Then write a basic HTML page and a css file that implement your idea.

Task 2: displaying blog posts

You are given a file blog_entries.php that you can include in your php code. The file defines an array $postarray, where each element represents a blog post. A blog post is in turn an array that consists of: Your task is to write a php program that creates a page with these entries. The page should be displayed using the CSS files designed in task 1. When you are generating HTML in your php code, make sure to insert appropriate HTML tags (for instance, em for the user name) and appropriate CSS classes if needed.

Task 3: displaying comments and user information

Here is the array of comments for one the post: blog_comments.php. For this task you need to include both the blog_entries.php and the blog_comments.php files into your php file so that you can get the text of the post as well. The page must display the post and all the comments.

You also need a page that displays user information: the login name and the display name. Since there isn't much test data, you can write the test data for thsi part on your own.

Keeping track of it all

When working in groups, you can use any one of the accounts. Note that you can copy files from another person's public_html, but not store them there. Make sure to backup files often and not to overwrite your own files when you are copying your partner's files. Printing out your files and/or sending them to yourself and your partner by e-mail doesn't hurt, either. And remember that communication is always a must: make sure to talk to your partner before you change something drastic in the project.

You must document the authorship of all work: when you have edited a file, write a comment in the beginning about what you did and when. If you both are working together, make a comment about that.


This page is a part of CSci 1101 course web site.