Keeping part of website always visible

C

Caleb

How do I keep a certain portion of my website always visible? eg: a
footer that is always displayed at the bottom regardless of the page,
also a section on the left with links to my home page, contact info,
links, etc. always displayed on the left w/out having to put that
stuff in on every single page.
 
D

dorayme

"Caleb said:
How do I keep a certain portion of my website always visible? eg: a
footer that is always displayed at the bottom regardless of the page,
also a section on the left with links to my home page, contact info,
links, etc. always displayed on the left w/out having to put that
stuff in on every single page.

Put it on every page in your case. What is the problem with that
for you?
 
C

Caleb

I'm going to have over 100 pages to put it on, and if I suddenly
decide I want to change something that means I will have to do it to
all of them :)
 
D

dorayme

"Caleb said:
I'm going to have over 100 pages to put it on, and if I suddenly
decide I want to change something that means I will have to do it to
all of them :)

OK. Why is this so hard? It is certainly dead simple using S & R
over whole folders in a text editor like BBEdit. Takes no time at
all. It takes the time to paste old in one field, new in another
and set to the whole website folder and enter. You don't, I
repeat, you don't have to go to each file to change it.

But I agree it is less elegant when you are uploading to a
webserver, especially on dialup! But if 100 pages is all, it is
not any effort really

Best way long term is server side control. You have a few
options. Server Side Includes, PHP includes. I use the latter
these days more and more. But I got on fine for years using just
S & R. But get tutes on "includes"
 
A

al jones

I'm going to have over 100 pages to put it on, and if I suddenly
decide I want to change something that means I will have to do it to
all of them :)

Caleb, I use orb as a preprocessor - that means (to me) that if I change my
header (which is stock over all my pages) then I just change the header,
run orb and upload my pages. I have 4 standard parts to my pages:
Header
Horizontal nav bar
Nav area on left
footer

Now, while I don't make changes to these often, when I do make and orb make
small work of it. What you do in you orb source file fname.orb is put in
[[$include somefile.orh]] and somefile.orh gets copied here when you run
orb to create the output.html file.

//al
 
N

Neredbojias

How do I keep a certain portion of my website always visible? eg: a
footer that is always displayed at the bottom regardless of the page,
also a section on the left with links to my home page, contact info,
links, etc. always displayed on the left w/out having to put that
stuff in on every single page.

The 2 commonest ways to do that are server-side includes and frames.
Frames can cause associative problems so read-up on server-side includes,
possibly using Google.
 
W

William Hughes

I'm going to have over 100 pages to put it on, and if I suddenly
decide I want to change something that means I will have to do it to
all of them :)

My header bar:

<IFRAME SRC="gen-header.htm" name="header1" height=85 align=top
scrolling="no" marginwidth=0 marginheight=0><!-- Alternate content for
non-supporting browsers --><H2 align=center>The Carrier
Project</H2></IFRAME>

menu:

<div class="sidebar">
<div class="gs-blu1 update">This page last updated:<br>21 January
2007</div>
<hr>
<IFRAME SRC="gen-mainmenu.htm" name="menu" height=2135 align=left
scrolling="no" marginwidth=0 marginheight=0><!-- Alternate content for
non-supporting browsers --><a href="gen-sitemap.htm"
target=_parent>Click here for menu</a></IFRAME>

and an information block:

<br clear="all">
<IFRAME SRC="bg-general.htm" name="bggeneral" height=420 align=top
scrolling="no" marginwidth=0 marginheight=0></IFRAME>
</div>

All I need to do to change the header/menu/info block on all 300-odd
pages of my site is make the changes to gen-header.htm,
gen-mainmenu.htm or the various bg-XXXXX.htm files.

Now, keeping these elements in place while the rest of the page
scrolls - that I can't help you with, sorry.
 
W

William Hughes

Best way long term is server side control. You have a few
options. Server Side Includes, PHP includes. I use the latter
these days more and more. But I got on fine for years using just
S & R. But get tutes on "includes"

Or IFRAME, if your ISP does not support SSI or php.
 
A

Andy Dingley

How do I keep a certain portion of my website always visible?

Page or site ?

For content on pages, then CSS "position: fixed;" is good, but not
widely supported. Searching that phrase will show you work-arounds
though.

For content across pages on a site, then use SSI (server side
includes), which are very widely discussed hereabouts and in the FAQ.
_Don't_ use an <iframe> though, that's a blecherous and massively
obsolete solution.
 
R

Roy A.

Page or site ?

For content on pages, then CSS "position: fixed;" is good, but not
widely supported.

Only by about 50% of the browsers.
Searching that phrase will show you work-arounds
though.

For content across pages on a site, then use SSI (server side
includes), which are very widely discussed hereabouts and in the FAQ.
Agree.

_Don't_ use an <iframe> though, that's a blecherous and massively
obsolete solution.

The iframe element is not obsolete or deprecated. The object element
is also an option. You should take a closer look at the elements:

http://www.w3.org/TR/html401/index/elements.html
 
A

Andy Dingley

Only by about 50% of the browsers.

When 50% can't make use of it, then that's a problem.

The iframe element is not obsolete or deprecated.

I never said it was either. <iframe> certainly isn't deprecated, nor
is it entirely obsolete for some cases where there's just no good
alternative. As SSI today is trivially available on almost every
hosting service though, then using <iframe> as a workaround for not
having it certainly is. <iframe> is never an elegant solution to doing
client-side assembly of something that should be being assembled on
the server.
 
R

Roy A.

I never said it was either.

Oh, but then we agree.
<iframe> certainly isn't deprecated,

I'm glad you got that part right.
nor is it entirely obsolete for some cases

So it isn't massively obsolete in most cases.
where there's just no good alternative.

There is always some cases where some solutions is better than others.
Try to Google it.
As SSI today is trivially available on almost every
hosting service though,

That's true, in some sense, so there is no need for me to say anything
about PHP server-side Include().
then using <iframe> as a workaround for not having it
certainly is.

So using <iframe> as a workaround (in this case) is entirely obsolete,
because server-side script is trivially available on almost every
hosting service. A agree, and I'm glad you're pointing that out.
<iframe> is never an elegant solution to doing
client-side assembly of something that should be being assembled on
the server.

Maybe not an elegant solution, and certainly not a good solution in
this case. The iframe element is, however, still there; and is widely
used and supported.
 
E

Ed Mullen

Caleb said:
How do I keep a certain portion of my website always visible? eg: a
footer that is always displayed at the bottom regardless of the page,
also a section on the left with links to my home page, contact info,
links, etc. always displayed on the left w/out having to put that
stuff in on every single page.

Iframes (and frames) have problems.

Javascript has problems.

Java and Flash have problems.

Browsers are not created equal.

There is no single approach that will solve all problems and remove all
obstacles other than making plain text HTML pages that have links as the
only interactive feature. Media (sound and video)? Nah. Problems.
Images? Well, a little better but still not universally consistent in
all cases ... problems.

Still ... if your choice is to create this design, then you need to
choose among the least of the evils. That is what I chose to do. I am
not able to use any server-side solution, my ISP simply doesn't offer
it. I like the drop-down menu concept, I wanted to be able to change
just a couple of files to change the menus and footer on all of my
couple-of-hundred Web pages by changing just a few files. I was willing
to cede those users who refuse to use javascript.

So. I use javascript to generate the menu content, and the footer
content, on the fly when a page is loaded. Should a user have js
disabled the page will degrade to a level of navagability, although it
certainly isn't as "pretty." But the user can get to everything on the
site. So be it. Paranoia about javascript threats on the Internet is
largely overblown. And to change every menu on 200 some pages on my
sites means editing two files. To change every footer on those pages
means editing one file. And, yes, I have a competent text editor in
which I create manually all of my pages and it does have Regular
Expression Search and Replace. Not anywhere close to the convenience of
what I do now. No, I have no desire to buy, learn, and embrace a CMS
software package. Nor do I want all the extra code added to 200+ pages
that that would entail.

Hey, your mileage may vary, just my 3.5 cents adjusted for inflation.
 

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,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top