This homework is due 2:20 pm, December 10, 2008, Taipei Time. Please prepare and hand in the homework in the specific way that is requested below. Your homework will be rejected if it is not prepared accordingly. No late homework will be accepted.
In this homework, you are asked to write a very simple web application
for posting articles to the Web and for generating a
RSS 1.0
feed for the articles that have been posted so far.
Specifically, the web application will provide an input form
with three text fields: title,
author, and content.
After the form is properly filled out with input to the three fields
and is submitted to the server, an HTML document will be generated
at the server site with the content part
becoming the body of the document, and the title
part as both the title and the heading (an h1 element) of the document.
The generated HTML will have a unique file name with extension
.html
. Furthermore, the RSS document at the server
site is updated with the posted article as the newest item in the feed.
Of course, the RSS feed must be readable by a RSS reader
(for example, by
this RSS 1.0 reader).
Another requirement is to validate the generated HTML file using
the W3C Markup Validation Service
to see if it is well-formed and valid. (If the input to
content is no good, the generated
HTML document will be in bad shape!
It is your responsibility to make sure the RSS document
is always in good shape.)
(50 points) An HTML document is correctly generated whenever the input form is filled out with proper text values and submitted. The RSS document is properly maintained to link to all the generated HTML documents.
(30 points) The generated HTML is validated using the W3C Markup Validation Service. The outcome (valid or not) is shown to the user in a separate web page.
(20 points) The first paragraph of the content part in the input form is used as the description in the corresponding RSS item element. The channel and item elements in the RSS document are properly annotated with Dublin Core elements such as dc:creator and dc:date.
You must prepare your homework in the following ways:
The input form is named post.html
but you can name other
programs or HTML documents whatever you wish. The generated HTML
documents are in a directory named data
in the same directory
under which file post.html
is located. The RSS document is called
rss.xml
and it is in directory data
as well.
You must also provide a readme.html
file outlining
how you complete this homework; put it in the same directory
under which file post.html
is located.
You must submit your homework in the following ways:
Put all the files in a zipped archive file. Note: Do NOT put your files in an another directory and zip that directory.
Upload your file by the deadline at
http://pomelo.iis.sinica.edu.tw/xmlcourse/upload/
For the PHP execution environment at the web server, please check the following link:
http://pomelo.iis.sinica.edu.tw/xmlcourse/php.php
Additional information about this homework can be found at the following URL:
http://www.iis.sinica.edu.tw/~trc/public/courses/Fall2008/homework4/