Next / Previous / Contents / TCC Help System / NM Tech homepage

6. Manifest constants

Next we set up some manifest constants, grouped at the top of the script for easy maintenance.

6.1. XHTML_DOCTYPE: Document type declaration for XHTML

Because the lxml package does not support generation of a DOCTYPE declaration, we'll just write one at the top of the file as ordinary text.

tccpage2.py
XHTML_DOCTYPE  =  (
    '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"\n'
    '    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">\n' )

6.2. XHTML_NS: The XHTML namespace URI

This is the namespace URI that identifies the XHTML document type.

tccpage2.py
XHTML_NS  =  "http://www.w3.org/1999/xhtml"

6.3. CSS_URL: Stylesheet location

Gives the URL of the stylesheet for TCC web pages.

tccpage2.py
CSS_URL  =  "http://www.nmt.edu/tcc/style.css"

6.4. TOP_NAV_SEP: Separator string for the top navigational bar

This is the string that separates elements of the page-top navigational bar.

tccpage2.py
TOP_NAV_SEP  =  " / "

6.5. TCC_MAIN_URL: TCC mainpage URL

This is the URL that people reach if they click on the TCC logo.

tccpage2.py
TCC_MAIN_URL  =  "http://www.nmt.edu/tcc/"

6.6. TCC_LOGO_URL: TCC logo URL

This is the URL of the official TCC logo.

tccpage2.py
TCC_LOGO_URL  =  "http://www.nmt.edu/tcc/images/logo.png"

6.7. BOT_NAV_SEP: Separator for page-bottom links

When a particular kind of page-bottom link has multiple destinations (e.g., a “See also” link), this string is placed between the links.

tccpage2.py
BOT_NAV_SEP  =  "; "