Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

CSS Forum


You are currently viewing our CSS Forum as a guest. Please register to participate.
Login



Reply
DIV layering.. need help x.x
Old 11-05-2006, 10:25 PM DIV layering.. need help x.x
Junior Talker

Posts: 1
Trades: 0
Ok sooo... On my computer the div layers look fine and positioned right but when i go onto my lap top the positioning is different.. what am i doing wrong??

Here is my URL: http://embrace-me.org/jamie/wp-conte.../mine/main.php

and here is my STYLE sheet that i used:
/* Div layer */
#main {
margin: 0 auto;
width: 800px;
text-align: left;
}

#main1 {
position: absolute;
top: 220px;
left: 100px;
width: 1000px;
height: 303px;
overflow: hidden;
background-image: url();
background-color: transparent;
}
#maincontent {
padding-top: 18px;
padding-left: 40px;
width: 500px;
height: 240px;
overflow: hidden;
background-color: transparent;
}
#menu {
float:left;
padding-top: 90px;
padding-left: 50px;
width: 190px;
height: 240px;
overflow: hidden;
background-color: transparent;
}

#newest {
position: absolute;
top: 10px;
left: 485px;
width: 180px;
height: 200px;
overflow: hidden;
background-color: transparent;
}
#maintitle {
position: absolute;
top: 25px;
left: 465px;
width: 190px;
height: 30px;
overflow: hidden;
background-color: transparent;
font-family: Verdana, Arial, Helvetica, sans-serif;
color: #663300;
font-size: 175%;
text-align: right;
}
virtualgirl is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 11-06-2006, 03:48 AM Re: DIV layering.. need help x.x
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,517
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
using position: absolute is where you are going wrong.

Learn about relative positioning and use the document flow to your advantage not against you, as absolute positioning will do until you learn how to use it in the right places.

BTW your link 404s out.
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- I SEO the only industry where all the cowboys are Indians?
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 11-07-2006, 08:12 PM Re: DIV layering.. need help x.x
frofi's Avatar
Extreme Talker

Posts: 236
Location: London
Trades: 0
Quote:
Originally Posted by chrishirst View Post
using position: absolute is where you are going wrong.

Learn about relative positioning and use the document flow to your advantage not against you, as absolute positioning will do until you learn how to use it in the right places.

BTW your link 404s out.

What is wrong with absolute positioning? Unless you are making CSS navigation bars and dropdown menus, absolute positioning works pretty well.
__________________
THE FORCE is with me at last! All I need now is some TALKUPATION ;)
frofi is offline
Reply With Quote
View Public Profile
 
Old 11-08-2006, 10:31 AM Re: DIV layering.. need help x.x
Experienced Talker

Posts: 37
Trades: 0
Quote:
Originally Posted by frofi View Post
What is wrong with absolute positioning? Unless you are making CSS navigation bars and dropdown menus, absolute positioning works pretty well.
In my eyes there is nothing wrong with it, you just have to understand the difference between absolute and relative, before you use either.
gaz545 is offline
Reply With Quote
View Public Profile
 
Old 11-08-2006, 02:23 PM Re: DIV layering.. need help x.x
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,517
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
Quote:
Originally Posted by frofi View Post
What is wrong with absolute positioning? Unless you are making CSS navigation bars and dropdown menus, absolute positioning works pretty well.
Actually navigation bars and/or drop downs is one of the places where using absolute postioning is required.

As noted in the original post
Quote:
On my computer the div layers look fine and positioned right but when i go onto my lap top the positioning is different.. what am i doing wrong??
using absolute positions can cause things to go wrong when viewing the pages at different resolutions.

There are very few instances where using absolute positioning is absolutely (pun intended) necessary, and before you start using absolute you need to understand what absolute means and how it will be applied to the elements.
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- I SEO the only industry where all the cowboys are Indians?
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 11-08-2006, 03:25 PM Re: DIV layering.. need help x.x
ADAM Web Design's Avatar
Canadastaninianite

Posts: 5,938
Name: Adam for web page design, not program
Location: Toronto, Ontario, Canada
Trades: 0
You're centering your layout. If you're going to do that, put position: relative on your #main div.

Absolute positioning is based on the nearest parent relative div. If one's not available, it's based on the body itself.
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
(my blog)


Please login or register to view this content. Registration is FREE
(with proof)
ADAM Web Design is offline
Reply With Quote
View Public Profile Visit ADAM Web Design's homepage!
 
Reply     « Reply to DIV layering.. need help x.x
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting 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 Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.24152 seconds with 12 queries