Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Developer Center > Floating box keeps moving

Floating box keeps moving
Thread Tools
Mac Elite
Join Date: Oct 1999
Location: Walnut Creek, California
Status: Offline
Reply With Quote
Mar 2, 2006, 11:15 PM
 
I realize this is probably a big-time noob question, but I am a noob so bear with me.

I wanted to use a floating layer to put a pic and some text across two cells in a column (I'm trying to avoid cutting the photo in two). The problem is that the layer's vertical placement (as I'm sure you know) is relative to the page's edge, and not the table cell I placed the div tag in. How can I keep the layer from moving when the page is resized?

[FONT="Tahoma"]Take a look for yourself. Be sure to resize your window to see the problem: My new site in progress[/FONT]

"Sing it again, rookie beyach."
My website
     
Professional Poster
Join Date: Jan 2001
Location: Salt Lake City, UT USA
Status: Offline
Reply With Quote
Mar 2, 2006, 11:55 PM
 
The table which your entire page is built within isn't anchored down.
Add an id to your style list , make it position: absolute; left: whatever; top: whatever;
and you're set. Here's some code, You'll probably want to tweak it:

#frank {position: absolute; top 49px; left: 50px;}

<table border="0" cellspacing="4" cellpadding="0" id="frank">
2008 iMac 3.06 Ghz, 2GB Memory, GeForce 8800, 500GB HD, SuperDrive
8gb iPhone on Tmobile
     
Miniryu  (op)
Mac Elite
Join Date: Oct 1999
Location: Walnut Creek, California
Status: Offline
Reply With Quote
Mar 3, 2006, 01:33 AM
 
That works, thanks.

I was hoping there would be a way to do it without anchoring the main table, but if not this works excellently. Thanks

"Sing it again, rookie beyach."
My website
     
Professional Poster
Join Date: Jan 2001
Location: Salt Lake City, UT USA
Status: Offline
Reply With Quote
Mar 3, 2006, 01:48 AM
 
Why did you not want to anchor it? The performance of the page is the same...
2008 iMac 3.06 Ghz, 2GB Memory, GeForce 8800, 500GB HD, SuperDrive
8gb iPhone on Tmobile
     
Clinically Insane
Join Date: Oct 2001
Location: San Diego, CA, USA
Status: Offline
Reply With Quote
Mar 3, 2006, 01:50 AM
 
I think you want to use rowspan. That's the old-school table layout way of doing it.
Chuck
___
"Instead of either 'multi-talented' or 'multitalented' use 'bisexual'."
     
Miniryu  (op)
Mac Elite
Join Date: Oct 1999
Location: Walnut Creek, California
Status: Offline
Reply With Quote
Mar 3, 2006, 07:31 PM
 
Originally Posted by SirCastor
Why did you not want to anchor it? The performance of the page is the same...
I have a number of friends with their monitors set at ridiculously high resolutions and they like their browser open full screen. If the main table is anchored, it sits high and to the left of their screen. I would prefer that it sits in the middle of the screen no matter what resolution it is at. It is a personal website, after all, and since my friends are a large part of the target audience, I have their set up in mind.

As far as using rowspan- it won't work. I've spent days trying to do it that way. I need the box with my picture in it to vary in length because I plan to change the text and pictures in it on a somewhat regular basis (look at the other sections of the site). I don't feel like cutting up my jpegs again and redoing the layout, I'm just going to anchor everything and be done with it.

Thanks a ton guys, and thanks for the site Chuckit.

"Sing it again, rookie beyach."
My website
     
Mac Elite
Join Date: Mar 2002
Location: Clogland
Status: Offline
Reply With Quote
Mar 4, 2006, 05:40 AM
 
Originally Posted by Miniryu
I have a number of friends with their monitors set at ridiculously high resolutions and they like their browser open full screen. If the main table is anchored, it sits high and to the left of their screen. I would prefer that it sits in the middle of the screen no matter what resolution it is at. It is a personal website, after all, and since my friends are a large part of the target audience, I have their set up in mind.

Any of them use windows? The layout is all over the shop when viewed with Win IE and Firefox.
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 09:31 PM.
All contents of these forums © 1995-2011 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.7 © 2000-2011, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2