File locations referred to by this page are relative to the www.cs
“document root”. To understand what this is, please read the relevant parts of WebFileLocations first.
CS news items start out visible on the front page at http://www.cs.uwaterloo.ca/ and are archived at http://www.cs.uwaterloo.ca/about/news/. Each item initially appears in four places:
These HTML files are all generated from a single file per news item by a script. The single source file is a text file at /about/news/[year]/[shortTitle].news, starting from the www.cs
document root. To create a new news item, choose a new "shortTitle" and create the .news file in this location.
The contents of the news file are two header lines, followed by as many paragraphs as needed. The first header line is the date, and looks like this:
Date: 2006-09-04
The date is in the international standard format yyyy-mm-dd.
The second header line is the title, like this:
Title: Some News Happened Today
Next a blank line separates the header lines from the actual article text.
The article text is written with blank lines separating one paragraph from the next. HTML can be included in the article text, but each '<', '>', '&', and '\' must be escaped by preceding it with a '\'. If one of these characters is not escaped, it will appear in the final news item as-is. Putting this all together, here is what a short news item file might look like:
Date: 2006-09-04 Title: Some News Happened Today Some really exciting stuff happened today in CS. Anything in this paragraph will appear on the front page and the main news page, as well as in the annual summary. So this paragraph shouldn't be excessively long. This is the second paragraph, which will only appear on the actual article page. If I want I can link to \<a href="http://www.example.com/somefile"\>another site\</a\> using a standard HTML <a> tag. This can also be used for putting in images using an <img> tag. Other tags might also conceivably be useful.
The news file is expected to be in the Windows-1252 character encoding. For "ordinary" characters in the ASCII range, this simply means that it is a standard ASCII file such as would be created by any text editor. In addition, however, many of the most common accent characters as well as handy symbols such as proper quote characters and em- and en-dashes are available. By default, MS-Word will use this encoding. Note however that the .news file must be a plain text file, so if using MS-Word one must use the "Text Only" option of "Save As…" to save the .news file.
Once the news item is ready to be posted, log in to Unix. Starting from the document root directory, run the following:
about/news/make
This will build the HTML files from the news items. Go on the web and make sure everything looks right.
-- IsaacMorland - 22 Sep 2006