

|
So you've got a website with 15+ pages and you're finding it a real pain to have to edit every single page just to show one link? I present to you... SSI, or Side Server Includes is a handy method which allows you to update the side bars of your site in one easy go! First of all you need to check to see if your host supports SSI. It should say so in their hosting package, but if you're unsure you can always e-mail them. If your host doesn't support SSI then you can either switch to a host that does ooor...you could update every single page by itself XD Secondly, you need to seperate your HTML code. To do this copy everything from the first <head> code all the way down to the way down to the start of the contents. Once you've done this paste it into a new file. You can call this file whatever you want, I'll call it leftmenu.txt Now copy everything from the bottom of the content to the last <head> code into another file. Again you can call it whatever, we'll call it rightmenu.txt (you can see how imaginative I am XD) Looking back at the file we've taken the codes out of, we should just be left with the actual contents of the page. Above the contents we need to put this code: This code is telling your computer to show whatever is in the leftmenu.txt folder on every page. Now go to the space below the content and put: Again, this is just telling the computer to show everything in the rightmenu.txt folder on every page. Don't forget to do this on all of your pages! Also, you can use PHP include for servers that does not support SSI but supports PHP. It's pretty much the same as SSI, only the tags are different: Pretty easy, eh? |