Jump to content

Float and Fixed Positioning?


Kevin M

Recommended Posts

In the layout I'm currently working on, I want to add an image that lets you go to the top of the page. There's two different navigation bars in the layout (one on the right, and one on the left). I want to have this image floated to the right of the right navigation bar. The only problem is, if I float it, then how can I position it fixed? Everything is inside of a container div, so I want it to stay in there, but also be positioned about 2 pixels from the bottom of the browser. I can't specify a pixel ammount for left or right because the layout is to be centered in the browser, so that would change. I quess I could use Java Script to see what screen resolution is set, but I'd rather save the hassle of that if possible.Any ideas are very appreciated!Thanks,Kevin :)

Link to comment
Share on other sites

you could add another div with the class 'footer' below the 2 coloumns, put the image in there and add this to your css:.footer{clear:both;text-align:right;}if that doesn't align the image to the right, then take out the text align and add this:.footer img{text-align:right;}that should work, or at least it has when i used it to align images.hope that helps:)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...