0

I am a beginner with a site made in Dreamweaver CS4 using HTML and CSS. Every page has a slightly different amount of content. The page content is designed to 'overlap' the footer, so that the top part of the footer can be seen behind the bottom of main content (images) and the bottom of the footer lines up with the bottom of the page.

I haven't been able to achieve a position where the footer allows for the same amount (height) of content to sit over it on every page, although I have been trying with changing all the margin and padding values etc. Currently the footer is jumping around from one page to another.

What I would like is for the footer to always be below all other content but with a negative top margin / padding effect, allowing the bottom of main content to sit on top of it - I just can't seem to make it happen! Advice would be very much appreciated. Thanks in advance.

noobug
  • 953
  • 1
  • 7
  • 11
  • If you post some code it would greatly help out, on a site like jsfiddle.net or something so people can mess with it and provide the best answer. – Loktar Mar 03 '11 at 14:04
  • Thanks very much - I have now solved the problem! It turned out that the footer was clearing everything above it so I wasn't able to incorporate the negative top margin I wanted. I used

    in the HTML code to clear the other content, then put the negative top margin on the footer and it is all placed exactly where I want. Not sure if this is the best way to do this but it was easy enough for a beginner and it achieved the desired result. Thanks though!
    – noobug Mar 03 '11 at 16:07

1 Answers1

0

Add this line before footer

<div style ="clear:both;" /></div>
Rishi Dua
  • 2,296
  • 2
  • 24
  • 35