Client Side Things
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Codewalkers ForumsOther TechnologiesClient Side Things

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Codewalkers Forums Sponsor:
AT&T devCentral & BlackBerry(r) Webcast Series: BlackBerry and GPS -Build Location Awareness into your BlackBerry Applications, July 10th-1:00PM EST. Register Today!
  #1  
Old May 4th, 2003, 08:24 PM
madhombre madhombre is offline
Codewalkers Newbie (0 - 499 posts)
 
Join Date: Apr 2007
Location: WI
Posts: 247 madhombre User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 2
postioning divs

is there a simple way to do this?

what I need to do is lay one div on top of another. the first being of relative posstion on the screen.

I can't make the second one relative because it comes out below the first.

I can't make it absolute because I dno't have the location of the relative first one.

I can't make the div inside the other because they need to be seperate for other reasons.

Is there an easy way or do I have to get all complex again!

Reply With Quote
  #2  
Old May 4th, 2003, 08:25 PM
madhombre madhombre is offline
Codewalkers Newbie (0 - 499 posts)
 
Join Date: Apr 2007
Location: WI
Posts: 247 madhombre User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 2
RE: postioning divs

I know I could javascript to get the position of the first and then move the second one, but if I can avoid do that I would be a happy man

Reply With Quote
  #3  
Old May 4th, 2003, 08:40 PM
madhombre madhombre is offline
Codewalkers Newbie (0 - 499 posts)
 
Join Date: Apr 2007
Location: WI
Posts: 247 madhombre User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 2
RE: postioning divs

even when I cheat and use relative - height (image in table so comes out below first)
it does place the second on top of the first BUT it also throws a big space in table where it should be!

I am using display: block on both images. may is that, I have positioing or space issues in the table cell UNTIL I put the second div in there. (That was a different problem!)

Reply With Quote
  #4  
Old May 4th, 2003, 09:21 PM
crisp crisp is offline
Codewalkers Newbie (0 - 499 posts)
 
Join Date: Apr 2007
Location: Holland
Posts: 336 crisp User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 2
RE: postioning divs

using a relative placed container, and putting the other 2 absolutely positioned in there should do the trick:

<div style="position: relative">
<div id="div1" style="position: absolute; top: 0px; left: 0xp; height: 100px; width: 100px">number 1</div>
<div id="div2" style="position: absolute; top: 0px; left: 0xp; height: 100px; width: 100px">number 2</div>
</div>

Reply With Quote
  #5  
Old May 4th, 2003, 09:27 PM
madhombre madhombre is offline
Codewalkers Newbie (0 - 499 posts)
 
Join Date: Apr 2007
Location: WI
Posts: 247 madhombre User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 2
RE: postioning divs

funny how it gets to a point where you always look for complex solutions and never dream there would a simple one.

DOH!!!!

such an easy fix, thanks again!

Reply With Quote
Reply

Viewing: Codewalkers ForumsOther TechnologiesClient Side Things > postioning divs


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway