Server Side Includes

  1. What is a server-side include?
    Server side includes allow your to include another chunk of HTML inside your webpage. For instance, My page might include a 'header.html' inside of the main page. Every page with this include will look the same and can be updated quickly by editing the included header.html file.
  2. May I use server-side includes?
    Yes, you may use server-side includes on monkeybrains. You may not use them to run scripts, but you may include static content.
  3. My includes are not being parsed, how do I get them to work?
    The filename must end in .shtml (e.g. name.shtml) to have the includes parsed. Let me say this again, "the extension of the filename must be .shtml!"
  4. Can my index.html page be parsed?
    Name the file index.shtml to have the your 'index' page of your site parsed. Please do not have a index.html and index.shtml in the same directory. You will only confuse yourself.
  5. Show me an example!
    okay, here is a sample file... click test-include.shtml to see it in action.
  6. Do all browsers support server-side includes?
    The broswer has nothing to do with the SERVER-SIDE of the web serving process. The file is built on the fly by the webserver and served whole to the browser. So, yes, all browsers will support CORRECTLY CREATED server-side files.
  7. Where do I find out more about server-side includes?
    Check out Apache's info on Includes..

Return to Support section of MonkeyBrains.net