Request Services
  Data Systems Services
 
Help Desk
Desktop Support
Web Development
Audiovisual
Application     Development
Classroom Support
  About Data Systems
  News & Announcements
  Quick Links
  Classroom Reservations
  Equipment Reservations
  Software Downloads
 
Data Systems Only! (Password Protected)
  Live Remote Assistance
 


Server Side Includes

There are a number of server side includes that our server software allows. Our SSI plug-in allows users to use special commands in HTML pages to display dynamic information to browsers and to simplify the structure of the sites. There are codes to display the current date and time, the file's last modified date, insert a standard header or footer file into several different pages, show a counter for individual pages, show or hide information based on a wide range of variables, and more. Please note that these codes will not work on your desktop - they will not start working till you send the document to the server, as the program runs off an application resident on the server.


Counters
One of the most frequently requested SSIs is the counter. All you need to do is insert the following line into your web page where you would like the hit number to appear.

<!--#exec cgi="/cgi-bin/counter/text_counter.pl"-->

We also have the ability to setup a graphical counter. So if you have found some graphical counter digits that you must have on your site, email webmaster@som.tulane.edu and we can help you get that setup.


Last Modified Date
Another very handy item is the last modified date. This automatically displays the date that the page was last modified - you don't have to remember to change it manually each time you update the page. The following code should be inserted into your page at the place where you want the date to appear:

<!--#config timefmt="%A, %B %d, %Y, %H:%M"-->
<!--#echo var="last_modified"-->

This will show up as "Friday, February 05, 1999, 09:56" (or whatever) when the page is uploaded to the server. You may want to add "Last modified date:" or other text to make it clear. Other date formats are available if you don't like the format of "day, month date, year, time". If you want to remove any element, %A is day; %B is month; %d is date; &Y is year; %H is hour and %M is minutes.


Standard Headers and Footers
The #include command inserts another file into the current page. This feature is extremely useful for displaying standard headers or footers or other elements that are common on multiple pages in your site. Should you need to make changes, you need only edit a single included file, instead of each separate page, to have the change reflected on every page that includes that file.

In order to take advantage of this, you must determine the elements that your pages have in common. If they each have their own title, keywords, description, etc., but all share the same body attributes (same background image or color) and the same opening images and text, you can create a document that you should name either "header.txt" or "header.incl" that will include all these shared attributes.

Then perhaps you have another set of items down at the bottom of each page that are common to a set of pages - the final image, links, last modified code, email address, etc. These can be added to a separate document that you can name "footer.txt" or "footer.incl".

In order to insert these elements into your pages, you need to select the spot where the elements would normally go and insert the following tag:

<!--#include virtual="header.incl"> (or header.txt, depending on which you used)

Determine the place where the footer elements would normally start, and insert the following code there:

<!--#include virtual="footer.incl"> (or footer.txt, depending on which you used)

Now, all you have to do to make changes to these common elements is make the changes in the header or footer document, send it to the server, and it will be immediately reflected in all the pages that call on that document! Makes it very easy to change backgrounds, layout, email addresses for contact people, links, and more.

Is all of this clear as mud? Contact us - we can show you how to do it.

Back to the top