1. Computing & Technology

Discuss in my forum

Updating your pages using SSI

By , About.com Guide

Your website may use style sheets to keep the color scheme and fonts consistent throughout your site, however you can take that one step farther and actually keep your code in shared files using PHP. We pull these files using SSI which stands for "Server Side Includes."

This does exactly what it says, it includes the files on the server end. So by the time the file gets to the user's browser, it's all one file, the user never sees that it has been pulled for multiple files.

You can use SSI for something as large as storing your websites entire template, or something as small as your copywrite lines for easy updating every year.

You can include a file within your PHP file using this code:

INCLUDE 'http://www.yoursite.com/path/to/file.php' ;

Of course you would change it to the actual URL and path of your file. You can included as many files as you want, you are not limited to one include per file.

©2012 About.com. All rights reserved.

A part of The New York Times Company.