Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using same style for many pages (sort of) 1

Status
Not open for further replies.

shmmeee

Programmer
Apr 17, 2001
104
0
0
GB
I'm setting up a movie and music review site and I want to be able to save myself time by having one template with the logo, common links etc. but the content in the middle changing. Can someone point me in the right direction to find out about this sort of stuff? I'm quite new to web development (I only really know about client-side stuff at the moment) so a simple intro to what I need would be ideal
 
Just use frames. Have a frame at the top for the logo and navigation and then a main frame for the content. The top frame doesn't need to change - just the main frame. Mise Le Meas,

Mighty :)
 
Could do I suppose, I just dont like frames, they always look poor for navigation unless the viewer has the same size browser window as the creator cos of the scrollbars. I was just hoping there was some kind of swanky database solution or something. I mean surley other sites that have a common theme don't repeat their code for every page? Maybe I'm just looking for a solution that doesn't exist.

Thanks anyway Mighty :)
 
How about Server Side Includes?

You could 'include' the header etc in each page. It would still reload, but would save you an awful lot of work.

SSI works like this -

<!--#include virtual=&quot;filename.html&quot; -->

Also, the page needs to be called *.shtml so that the server recognises SSI commands.

Handy hint if you use it - Don't have <body>,<head> etc in the included files. makes a mess. Dean Owen
 
Works with asp pages too.
b[sup]2[/sup] - benbiddington@surf4nix.com
 
Do I need to set up anything for SSI or is it as simple as it looks? (i.e. just put the include in and the server will recognize it)
 
As long as the server is configured for SSI ( Check FAQ or email your admin ), then yes, it is as simple as it appears.

Just do what outlined above.

Dean Owen
 
try using the same template but making the body region editable and all the other regions locked. u can keep adding new text in the body region.
 
Includes!! I use includes with templates and CSS regularly. It has made my life so much easier. &quot;Absorb what is useful, discard what is not. Add what is uniquely your own.&quot; - Bruce Lee - The Tao of Jeet Kune Do
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top