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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

opening others pages in part of index page

Status
Not open for further replies.

treta

Technical User
May 13, 2004
47
Hi.
I would like to have my site like this:Having the first page(index.html)can the others pages open in the right side of the index page?

Thanks
 
Thanks to point me to FRAMES.
I'll look to see some thing about (I don't know how to aproach to frames)
 
No frames for me! I do make extensive use of Server Side Includes to put standard content into each page (look carefully and you'll see that most pages are called something.shtml - which gives this fact away). You can read up more about SSI in faq253-3309 and faq253-2000 .

I'm still using old-fashioned tables to lay out my pages (fancy new pure CSS layout site currently under construction!), it's quite simple to build a two-column site like this:
Code:
<html>
<head>
  <title>2 col demo</title>
</head>
<body style="margin:0">
[COLOR=red]<table width="100% height="100%">
<tr>
<td width="200">
This is the menu column, it's fixed to 200 pixels wide.
You could give it a backgound colour or image if you liked.
</td>
<td>[/color]
<h1>Demo</h1>
<p>This is the actual content of the page, it fills the rest of the width.</p>
[COLOR=red]</td></tr></table>[/color]
</body>
<html>
The bits of code that I've coloured in red are actually sourced from SSI files. The actual page as stored on the server looks something like
Code:
<html>
<head>
  <title>2 col demo</title>
</head>
<body style="margin:0">
<!--#include virtual="/template/top.txt" -->
<h1>Demo</h1>
<p>This is the actual content of the page, it fills the rest of the width.</p>
<!--#include virtual="/template/bottom.txt" -->
</body>
<html>
Note that if this page were served up without including the files (on my local PC for example), it's still a valid HTML document, just without the navigation bits. Also note that I can completely change the layout of all pages by simply editing top.txt and/or bottom.txt. Neat, eh?

-- Chris Hunt
 
Chris Thanks
I saw all links and I'll try to learn with
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top