467,926 Members | 1,473 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 467,926 developers. It's quick & easy.

fixed images and layers advice please

Hi,

Is it possible to simulate frames behaviour with CSS?

Currently, I've used CSS to create the visual look of my old framed
site.
For this I've used styles that place the images at absolute positions.

Then I thought, if I fixed the image positions, the images will stay
put and the 'body' will scroll up, like in frames.

This too worked, except the 'body' content scrolled over the fixed
images.

The 'body' position is also set with a CSS absolute position.

Can I assign layers to the images and 'body' styles so that the 'body'
is beneath the images when it scrolls up?

Note part of the 'frame' at the top is set up with a repeat-x
background tile.

Below are the stylesheet snippets in question:
body {
color: #000000;
background-color: #ffffff;
margin-top: 0px;
margin-left: 0px;
margin-right: 0px;
background: white url("images/index_topstrip.gif");
background-repeat: repeat-x;
background-position: top; <--not yet fixed position of this one
}

..style0 <--this one for the "body"
{
position: absolute;
top: 145px;
left: 160px
}

..style10 <--these ones onward for the fixed images
{
position: fixed;
top: 2px;
left: 0px
}

..style11
{
position: fixed;
top: 80px;
left: 0px
}

..style12
{
position: fixed;
top: 132px;
left: 0px
}
etc etc

Jul 21 '05 #1
  • viewed: 4748
Share:
2 Replies
Els
hq******@hotmail.com wrote:
Hi,

Is it possible to simulate frames behaviour with CSS?

Currently, I've used CSS to create the visual look of my old framed
site.
For this I've used styles that place the images at absolute positions.

Then I thought, if I fixed the image positions, the images will stay
put and the 'body' will scroll up,
yes.
like in frames.
no :-)
This too worked, except the 'body' content scrolled over the fixed
images.
of course ;-)
The 'body' position is also set with a CSS absolute position.

Can I assign layers to the images and 'body' styles so that the 'body'
is beneath the images when it scrolls up?
I'm guessing you are talking a "top frame" which stays visible all the
time while the "main frame" is a scrollable area?
Note part of the 'frame' at the top is set up with a repeat-x
background tile.
[snip stylesheet snippets]
etc etc


1) please provide a URL so we can see what you're talking about
2) reconsider the simulation of frames - why would you want the top
'frame' to stay put? Let it scroll up with the rest of the page, like
all normal* pages do? If a chunk of 'top frame' is to stay visible at
all times, it will also at all times eat up space in my window, that I
might want (need even!) to display the actual content of your page.

* overgeneralised, I know.

--
Els http://locusmeus.com/
Sonhos vem. Sonhos v„o. O resto ť imperfeito.
- Renato Russo -
Jul 21 '05 #2
hq******@hotmail.com wrote:
Hi,

Is it possible to simulate frames behaviour with CSS?

Frameless Frames, the simulation of Frames behaviour with CSS.
http://www.ddj.com/documents/s=2988/nam1012434075/
by Eric Meyer is from early 1998, but explains clearly and easily.
Here is an example:
http://www.info.com.ph/~etan/w3panth...esnebulae.html
You can find others if you look for them.

--
Gus
Jul 21 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

98 posts views Thread by Pamel | last post: by
3 posts views Thread by Dave | last post: by
2 posts views Thread by Trent | last post: by
4 posts views Thread by Rob Freundlich | last post: by
4 posts views Thread by VR | last post: by
61 posts views Thread by phil-news-nospam | last post: by
3 posts views Thread by blobb | last post: by
8 posts views Thread by dougawells | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.