SSI ( Server side includes)
SSI is almost anything which is controlled by your host's server and which effects your web site. It mostly refers to the .htaccess file though. Not all hosts have this facility and even if they do it doesn't always show up when you look at the server side of FTP. You may be able to find it by going into your file manager on your host's site though.
How to make a .htaccess file?
Either find it on your host's server and download it to your computer or you will have to make it in notepad. Notepad will not allow you to 'save as' without some sort of file extension. So you can save it as .txt and once uploaded, rename it to .htacess Note that it does not have any file extension name and has a . in front of it.You can use this file to set dates, last modified pages, footers and password-protected directories.
What most people now use them for is to redirect pages.
404 pages
A very useful command is to ensure that a 404 page doesn't appear like that. To do this create an html page that you would like your visitors to see if they request a non-existent file, using all of the headers, graphics, etc. that your other pages have. Save this page with the name error.html (or any name you prefer).Then place the command ErrorDocument 404 http://www.mydomain.com/error.html into the .htaccess file and upload the .htaccess file and the error.html file to the root directory.
Recently, as I was transferring knowledgecollegetutors to ozwebhub, I used .htaccess to redirect individual pages. I used the command : redirect 301 /oldfile.html http://www.ozwebhub.com/newfile.html or htm if that was the extension. You can use this sort of command if you change the name of a file, move it, or delete it. This avoids any 404 pages.
To redirect an entire domain permanently to another I used
this command.Redirect permanent / http://www.ozwebhub.com/
RewriteEngine onRewriteCond %{HTTP_HOST} ^knowledgecollegetutors.com$ [OR]RewriteRule
^(.*)$ http://www.ozwebhub.com/ [R=301,L]ozwebhub is the NEW domain. knowledgecollegetutors
is the OLD domain.
This ensures that all subdirectories are included. Instead of 301 you can use the word 'permanent' if you wish.Let's say your host requires that pages with SSI directives have a .shtml extension. However, over time all of your pages have been linked to and indexed by search engines using their current .html extensions. There is a way around that.
Place the following into your .htaccess file
AddType text/html .html
AddHandler server-parsed .html
You can have as many commands in the .htaccess file as you wish. I found there was a limit to adding oldfile to newfile in this .htaccess file though. At one point the command resulted in an everlasting loop.redirect 301 /oldfile.html http://www.ozwebhub.com/newfile.html I really like javascript menus because they are so easy to change across the site. So have a look at javascript menus too.
Another way of changing site contents quickly is to use an iframe for your menu. You can change just the one page then each time you add contents.
© Jenny Campbell