Today's Posts Follow Us On Twitter! TFL Members on Twitter  
Forum search: Advanced Search  
Navigation
Marketplace
  Members Login:
Lost password?
  Forum Statistics:
Forum Members: 24,254
Total Threads: 80,792
Total Posts: 566,472
There are 1581 users currently browsing (tf).
 
  Our Partners:
 
  TalkFreelance     Design and Development     HTML/XHTML/DHTML/CSS :

IE problem with absolute positioning

Thread title: IE problem with absolute positioning
Closed Thread    
    Thread tools Search this thread Display Modes  
04-23-2008, 02:48 AM
#1
marcelomdsc is offline marcelomdsc
marcelomdsc's Avatar
Status: I'm new around here
Join date: Dec 2007
Location: Santa Rosa, Ca
Expertise:
Software:
 
Posts: 15
iTrader: 0 / 0%
 

marcelomdsc is on a distinguished road

  Old  IE problem with absolute positioning

Hello, I started working on a new site a little while ago and I'm having problems with the layout in IE.
In IE7 when you resize the browser's window, the news articles stay in the same place breaking out of it's containing box.
I've never encounter this problem before, does somebody know how to fix it?

Thanks, Marcelo.

http://studios29.com/sars/

04-23-2008, 03:58 PM
#2
nontemplates is offline nontemplates
Status: Junior Member
Join date: Jan 2008
Location:
Expertise:
Software:
 
Posts: 27
iTrader: 0 / 0%
 

nontemplates is on a distinguished road

  Old

Unless thee is a compelling reason you should stay away from absolute positioning. Layout your design using traditional divs with floats.

04-23-2008, 07:45 PM
#3
marcelomdsc is offline marcelomdsc
marcelomdsc's Avatar
Status: I'm new around here
Join date: Dec 2007
Location: Santa Rosa, Ca
Expertise:
Software:
 
Posts: 15
iTrader: 0 / 0%
 

marcelomdsc is on a distinguished road

  Old  thanks but

that wasn't very helpful. And yes the only reason I'm using absolute positioning is because it's the best way to do that.

04-25-2008, 02:27 AM
#4
natekasco.com is offline natekasco.com
Status: I'm new around here
Join date: Apr 2008
Location: Ohio
Expertise:
Software:
 
Posts: 24
iTrader: 0 / 0%
 

natekasco.com is on a distinguished road

Send a message via AIM to natekasco.com Send a message via MSN to natekasco.com Send a message via Yahoo to natekasco.com

  Old

i used to use absolute positioning because i never realized there were more than one resolution haha. that was back in the day.

now i use floats which basically you just use css classes such as float:left; and float:right;

just make sure you make an empty div with class of "clear" in it with the css as:

.clear{
clear:both;
}

i hope this helps. you will obviously need to make some changes, but it will be worth it so that your site is completely cross-browser compatible! =]

04-25-2008, 07:16 PM
#5
solarisedesign is offline solarisedesign
Status: Junior Member
Join date: Apr 2008
Location: Edinburgh
Expertise:
Software:
 
Posts: 49
iTrader: 1 / 100%
 

solarisedesign is on a distinguished road

Send a message via MSN to solarisedesign

  Old

Absolute positioning can be very useful if used correctly. One thing I found which always seems to help is that you must ensure that the parent container of the absolutely positioned item has a position type of "relative" specified, so that the absolute item is anchored correctly

Where you have <div id="news">

try <div id="news" style="position:relative;">

(or stick that in the stylesheet for neatness)

04-27-2008, 04:46 PM
#6
marcelomdsc is offline marcelomdsc
marcelomdsc's Avatar
Status: I'm new around here
Join date: Dec 2007
Location: Santa Rosa, Ca
Expertise:
Software:
 
Posts: 15
iTrader: 0 / 0%
 

marcelomdsc is on a distinguished road

  Old

thanks you guys.
I know about floats and what they do, what we have absolute positioning for a reason, for this kind of stuff floats would be a nightmare.
And I also know that I have to have the parent element set to relative otherwise the element is absolute positioned to the browser's window.

Somebody else told me the solution in a different forum. The problem with my code was that I had set a fixed width and margin-right and left to auto in the body tag, I moved those properties to my wrapper div and it's all good now.

Thanks.

Closed Thread    


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

  Posting Rules  
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump:
 
  Contains New Posts Forum Contains New Posts   Contains No New Posts Forum Contains No New Posts   A Closed Forum Forum is Closed