-
1. Re: Absolute Positioning a div
SugnaShane May 2, 2011 8:00 AM (in response to garynng)You need to put the absolute float in a container to control the position.
<div class="twitter-container">
<div class="twitter-feed">code</div>
</div>
float "twitter-container" left with a width
float twitter-feed absolute
twitter-feed will be absolute positioned to it's container which is "twitter-container"
-
2. Re: Absolute Positioning a div
adninjastrator May 2, 2011 8:14 AM (in response to garynng)The actual display of your <div> will very depending on whether or not it's parent container (<div>) also has a declared position.
That is, if it's parent container DOES NOT also have a declared position, the child <div> will do 1 of 2 things.
If position:relative, it will position as desired but space will be left as though that element was still in the natural flow. So you may move the 500 X 100 element down and over, but a 500 X 100 space will be left, as though it was still there.
If position:absolute, child is positioned relative to browser window and that position does not change even if window contracts or expands.So be sure to give a declared position to both the parent and the child <div>.
Best wishes,Adninjastrator
-
3. Re: Absolute Positioning a div
John Waller May 2, 2011 1:01 PM (in response to garynng)Put your absolutely positioned div inside a relatively positioned div wrapper.
See
http://www.barelyfitz.com/screencast/html-training/css/positioning/ (tab 4)
http://css-tricks.com/absolute-positioning-inside-relative-positioning/
-
4. Re: Absolute Positioning a div
DJ-G May 2, 2011 7:33 PM (in response to garynng)1 person found this helpfulDon't use left, use right positioning in # pixels from the right side of the page.
-
5. Re: Absolute Positioning a div
garynng May 3, 2011 9:42 AM (in response to DJ-G)Thank you everyone! Who would have thought that adding a twitter button would take so much thought?