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
Old 07-28-2008, 06:14 PM Help with Div Tags
Junior Talker

Posts: 3
Name: Tom
Trades: 0
I am pulling my hair out over this one. See pictures below. I have my main content in Div Tags that are made to fit 800 x 600 screen resolution, when i resize my browser window the main content resizes itself to occomodate the window. What i want is for another Div Tag or Div Layer of certain size to be positioned over the main content Divs in a certain spot and move when the screen resolution is changed or the window is resized. Surely this cant be hard todo with some CSS??



WebbyTom is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 07-28-2008, 07:45 PM Re: Help with Div Tags
vangogh's Avatar
Post Impressionist

Posts: 10,688
Name: Steven Bradley
Location: Boulder, Colorado
Trades: 0
I'm not quite sure I understand the issue. Do you have any code or a link to a page online we could see?

If I'm understanding right the issue is that you want parts of the design to resize as someone resizes the browser. If the main content area already is resizing why do you need another layer on top. Could you just place things in the main content div and let them resize with it? If you place something inside the content div then you can have that resize with the content div or move with in it by keeping the inner div a fixed size and letting the margin around it be a relative measurement.

By the way the design itself is really nice. I like how it looks.
__________________
l Search Engine Friendly Web Design |
Please login or register to view this content. Registration is FREE

l Tips On Marketing, SEO, Design, and Development |
Please login or register to view this content. Registration is FREE

l
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
vangogh is offline
Reply With Quote
View Public Profile Visit vangogh's homepage!
 
Old 07-28-2008, 08:20 PM Re: Help with Div Tags
Junior Talker

Posts: 3
Name: Tom
Trades: 0
Yeah i want a layer over top of the main content because it will hold a css menu. Here is the code

</style>
</head>

<body>


<!-- Begin Wrapper -->


<div id="wrapper">


<!-- Begin Content -->
<div id="content"></div>
<!-- End Content -->

<!-- Begin Content 2 -->
<div id="content2"></div>
<!-- End Content 2 -->


<!-- Begin Content 3 -->
<div id="content3"></div>
<!-- End Content 3 -->



</div>
<!-- End Wrapper -->







</body>
</html>

and CSS

* { padding: 0; margin: 0; }

body {
font-family: Arial, Helvetica, sans-serif;
font-size: 13px;
background-image: url(back.jpg);
background-repeat: repeat;
text-align: center;
}
#wrapper {
width: 976px;
margin-top: 0;
margin-right: auto;
margin-bottom: 0;
margin-left: auto;
}
#content {
width: 976px;
height: 561px;
background-image: url(images/index_01.png);
background-repeat: no-repeat;
padding-right: 10px;
padding-left: 10px;
margin: 0px;
}

#content2 {
height: 431px;
width: 976px;
background-image: url(images/index_02.png);
background-repeat: no-repeat;
}

#content3 {
background-image: url(images/index_03.png);
background-repeat: no-repeat;
height: 78px;
width: 976px;
}
WebbyTom is offline
Reply With Quote
View Public Profile
 
Old 07-28-2008, 11:41 PM Re: Help with Div Tags
Jdinh04's Avatar
Super Talker

Posts: 140
Name: Johnny Dinh
Location: East Lansing, MI
Trades: 0
I think basically what you need is a master DIV and the content will be inside the master DIV that way the position of the content won't change and will be inside a 800x600 size DIV. See above at Tom's post.
Jdinh04 is offline
Reply With Quote
View Public Profile Visit Jdinh04's homepage!
 
Old 07-29-2008, 03:43 AM Re: Help with Div Tags
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,517
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
can we recap a little?

Quote:
I have my main content in Div Tags that are made to fit 800 x 600 screen resolution,
#wrapper {
width: 976px;
Doesn't fit in to a 800px wide window.

Quote:
that are made to fit 800 x 600 screen resolution, when i resize my browser window the main content resizes itself to occomodate the window
If it is fixed width, It shouldn't be resizing anywhere.

Your posted code is set for is a 976px centred layout. There is nothing in that layout that should be resizing at all.
__________________
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 07-29-2008, 07:40 PM Re: Help with Div Tags
vangogh's Avatar
Post Impressionist

Posts: 10,688
Name: Steven Bradley
Location: Boulder, Colorado
Trades: 0
First Chris is right. If you've explicitly set px widths for things than your layout is going to remain a fixed size.

I still don't see why you need a layer on top of the content layer for your css navigation. I would put the navigation inside the content layer

div id="content">
<div id="navigation">html for navigation here</div>
</div>

Then assuming you've coded things so the content div and the navigation div use relative measurements (%, em) the navigation div will expand/contract with the content div. Unless I'm missing something there really isn't any reason why the navigation div has to sit on top of the content div.

If I am missing something I apologize and ask for a little more explanation.
__________________
l Search Engine Friendly Web Design |
Please login or register to view this content. Registration is FREE

l Tips On Marketing, SEO, Design, and Development |
Please login or register to view this content. Registration is FREE

l
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
vangogh is offline
Reply With Quote
View Public Profile Visit vangogh's homepage!
 
Reply     « Reply to Help with Div Tags
 

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.23561 seconds with 12 queries