Topic: CSS Positioning screwed up when browser is not maximized (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=10901" title="Pages that link to Topic: CSS Positioning screwed up when browser is not maximized (Page 1 of 1)" rel="nofollow" >Topic: CSS Positioning screwed up when browser is not maximized <span class="small">(Page 1 of 1)</span>\

 
foundrymusicjeff
Obsessive-Compulsive (I) Inmate

From: Manalapan, NJ 07726
Insane since: Feb 2003

posted posted 02-05-2003 20:45

http://www.foundrymusic.com/home/new_home_template.htm


Why is it when i use absolute position and i establish my absolute locations for div tags it looks fine when the browser is maximized, but the absolute positioning moves when the browser is not maximized. Like if i un-maximize it and resize the screen, they start moving around as i drag the window size. Anyway I can preven this from happening?

DL-44
Maniac (V) Inmate

From: under the bed
Insane since: Feb 2000

posted posted 02-05-2003 22:56

Works fine for me in IE 6.0.

What browser are you using?



foundrymusicjeff
Obsessive-Compulsive (I) Inmate

From: Manalapan, NJ 07726
Insane since: Feb 2003

posted posted 02-05-2003 23:21

ie 6

look at the text box...

if i resize the browser or change resolutions the positioning of all my elements become fucked...

the page is cented but the div elements have absolute values that must change when the browser is resized or resolution is changed...

Suho1004
Maniac (V) Inmate

From: Seoul, Korea
Insane since: Apr 2002

posted posted 02-06-2003 00:39
quote:
Anyway I can preven this from happening?



Yep, just have the page reload whenever the browser window is resized.

You can do this with an addition to the body tag:

<BODY onResize="window.location.href = window.location.href;">

I've also seen it done straight in DHTML(the following is a single line of code):

if(document.layers){origWidth=innerWidth;origHeight=innerHeight;onresize=function(){if(innerWidth!=origWidth&#0124; &#0124;innerHeight!=origHeight)location.reload()}}

I seem to remember doing a slightly different version of the first one way back when I actually did things like that, but now I can't remember what it was. Anyway, one of those should do the trick.

foundrymusicjeff
Obsessive-Compulsive (I) Inmate

From: Manalapan, NJ 07726
Insane since: Feb 2003

posted posted 02-06-2003 18:15

that doesnt work....i think i can use frames though which migh twork...

bitdamaged
Maniac (V) Mad Scientist

From: 100101010011 <-- right about here
Insane since: Mar 2000

posted posted 02-06-2003 18:36

When you are aligning the table to center it's going to throw off all absolutely positioned elements on resize.

You may want to consider switching it all to css.



.:[ Never resist a perfect moment ]:.

Suho1004
Maniac (V) Inmate

From: Seoul, Korea
Insane since: Apr 2002

posted posted 02-07-2003 01:14

My bad... I didn't even look at your source. I figured that since you were talking about absolute positioning you weren't using a table for layout. I would agree with bitdamaged on this one.



Post Reply
 
Your User Name:
Your Password:
Login Options:
 
Your Text:
Loading...
Options:


« BackwardsOnwards »

Show Forum Drop Down Menu