how to include a html navbar when using framesets

R

Rahul

I was used to adding a navbar for navigation etc. by including a standard
snippet within <body> tags like so:

###################
<head>
<link href="topbar.css" rel="stylesheet" type="text/css" />
</head>

<body>
<?php include("navbar.html"); ?>
foo content
</body>
###################

But apparantly framesets cannot go within body tags. One of my new
webpages has four charts on it like so:

http://dl.dropbox.com/u/118481/debug_frames.jpg

############
<html>

<frameset rows="50%,50%">
<frameset cols="50%,50%">
<frame src="euclid_jobs_waittimes.html" />
<frame src="euclid_historic_cpuhrs_share.html" />
</frameset>
<frameset cols="50%,50%">
<frame src="euclid_jobs_servers.html" />
<frame src="euclid_jobs_runtimes.html" />
</frameset>
</frameset>

</html>
################

But now I am lost as to how I can still include the navbar. I can't
figure out how to combine frames and a html navbar that needs the <body>
tags. Any tips?
 
B

Beauregard T. Shagnasty

I was used to adding a navbar for navigation etc. by including a
standard snippet within <body> tags like so:
But now I am lost as to how I can still include the navbar. I can't
figure out how to combine frames and a html navbar that needs the
<body> tags. Any tips?

Yet another frameset.
 
J

Jerry Stuckle

Rahul said:
I was used to adding a navbar for navigation etc. by including a standard
snippet within <body> tags like so:

###################
<head>
<link href="topbar.css" rel="stylesheet" type="text/css" />
</head>

<body>
<?php include("navbar.html"); ?>
foo content
</body>
###################

But apparantly framesets cannot go within body tags. One of my new
webpages has four charts on it like so:

http://dl.dropbox.com/u/118481/debug_frames.jpg

############
<html>

<frameset rows="50%,50%">
<frameset cols="50%,50%">
<frame src="euclid_jobs_waittimes.html" />
<frame src="euclid_historic_cpuhrs_share.html" />
</frameset>
<frameset cols="50%,50%">
<frame src="euclid_jobs_servers.html" />
<frame src="euclid_jobs_runtimes.html" />
</frameset>
</frameset>

</html>
################

But now I am lost as to how I can still include the navbar. I can't
figure out how to combine frames and a html navbar that needs the <body>
tags. Any tips?

Try an HTML newsgroup.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
(e-mail address removed)
==================
 
D

Denis McMahon

Try an HTML newsgroup.

What Jerry means is:

(a) Ask in an HTML newsgroup where in your frameset you can insert
content (i.e. the navigation bar).

(b) Insert your variant of "<?php include('nav.php'); ?>" at the
relevant place.

Rgds

Denis McMahon
 
A

Adrienne Boswell

I was used to adding a navbar for navigation etc. by including a
standard snippet within <body> tags like so:

###################
<head>
<link href="topbar.css" rel="stylesheet" type="text/css" />
</head>

<body>
<?php include("navbar.html"); ?>
foo content
</body>
###################

But apparantly framesets cannot go within body tags. One of my new
webpages has four charts on it like so:

http://dl.dropbox.com/u/118481/debug_frames.jpg

############
<html>

<frameset rows="50%,50%">
<frameset cols="50%,50%">
<frame src="euclid_jobs_waittimes.html" />
<frame src="euclid_historic_cpuhrs_share.html" />
</frameset>
<frameset cols="50%,50%">
<frame src="euclid_jobs_servers.html" />
<frame src="euclid_jobs_runtimes.html" />
</frameset>
</frameset>

</html>
################

But now I am lost as to how I can still include the navbar. I can't
figure out how to combine frames and a html navbar that needs the
<body> tags. Any tips?

I see no need for frames here. I would do something like:

<div id="header">
<?php include "nav_inc.php"; ?>
</div>
<div id="waittimes">
<?php include "waittimes.php"; ?>
</div>
<div id="shares">
<?php include "shares.php"; ?>
</div>
<div id="servers">
<?php include "servers.php; ?>
</div>
<div id="runtime">
<?php include "runtime.php"; ?>
</div>
<div id="footer">
<?php "footer_inc.php"; ?>
</div>

Then your CSS:
#header {/* your header styles */}
#waittimes, #shares, #servers, #runtime {width:45%; height:50%;
overflow:scroll;}
#waittimes, #servers {clear:left; float:left;}
#footer {clear:left; /* other footer styles */}

Play around with margins to suit.
 
R

Rahul

I see no need for frames here. I would do something like:

<div id="header">
<?php include "nav_inc.php"; ?>
</div>
<div id="waittimes">
[snip]

Thanks! That works too. I was just using frames before as it allowed me a
nice way to get the ability to automatically scroll the plots when they
happen to be large in size. But your solution fixes that.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,982
Messages
2,570,186
Members
46,740
Latest member
JudsonFrie

Latest Threads

Top