Creation of Institute Websites

With the introduction of a new layout for the institute's homepage there is now the option to adapt said layout for the sites of workgroups and members of staff. This has the advantage that you no longer have to worry about your site's compatibility with different browsers and on the other hand it allows us to change the site's layout without having to edit a large number of individual sites.

To use the institute's layout template, simply use the extension ".htmpl" (for HTML Template) instead of ".html" for the file name. Additionally you have to make a few small adjustments to the file. You do not need to use HTML declarations, no header and no opening body-tag. You simply begin with your first headline and do not end the file with the usual "</body></html>". This information is automatically inserted by us. An example site could look like this:

<hl>Headline</hl>
<p>Text</p>

Warning: If your WWW-directory contains both a file with the ".html" extension as well as one with the ".htmpl" one, the ".html"-file will take priority. You will have to either delete or move it in order for the template-file to be used.

Furthermore the template-system allows you to provide multilingual versions of your website. For this please use the pseudo-HTML-tag <t>:

<p>
  <t>
    <en>Example</en>
    <de>Beispiel</de>
  </t>
</p>

In this case links to the different language versions will be provided by the template. The user's choice of language will be saved, so that other pages will be presented in that language as well, if possible.

You can also add a custom prefix to the page title by adding a line like [% title = 'Jon Doe' %] to your .htmpl file. In case of a multilingual page, use title.de and title.en instead for a page title in the user's selected language. Unfortunally, it does not work to use the <t> pseudo tag inside the title Variable.

Advanced users may further customize the system's behaviour via a configuration file called config.inc. The file must consist of Parameter=Value lines. Its values affect the directory it resides in plus anything further down the directory tree unless overridden by more specific config.inc files located in sub directories. Parameter show_news controls whether the News box appears in the top right corner of each page (the default of show_news=1 inserts the box, use show_news=0 to make it disappear). Parameters type and charset specify the content-type resp. charset headers emitted by our server and default to text/html and ISO-8859-1, respectively). Parameter default_lang sets the default language (with the default default being de, i. e., german); use lang_selector=0 to disable the languge selector (i. e. if you only provide a single language). It's even possible to specify a custom template via the style parameter; please contact us if you want to make use of this feature (the Library's Website does).

Enven though the files now have a different extension in the filesystem, you still have to use the old ".html"-format in your browser. If, for example, you want to publish test.htmpl, simply enter the URL <http://www.math.uni-bonn.de/people/[USERNAME]/example.html> in your browser. Our webserver automatically converts filenames so you do not have to change your links. I.e. do not use URLs with the ".htmpl" extension. In addition we would like to ask you to abstain from using any extensions, i.e. to use the format <http://www.math.uni-bonn.de/people/[USERNAME]/example> instead of <http://www.math.uni-bonn.de/people/[USERNAME]/example.html>, in order to facilitate future changes to the system. If you are interested in the reasons for this, we recommend the article "Cool URIs don't change" by Tim Berners-Lee.

Suggestions for improvements are of course welcome!