Go Back   Website Publisher Forums > Website Development > HTML, CSS, Layout, and Design

Notices

Reply
 
Thread Tools Rating: Thread Rating: 1 votes, 1.00 average.
Old 06-06-2006, 07:06 PM   #1
deronsizemore
Senior Member
 
deronsizemore's Avatar
 
Join Date: Sep 2005
Posts: 981
First go at a fluid layout...few small issues

Okay, so I've been toying around with fluid layouts for my next site. At this point, I'm not so sure it wouldn't be easier to just use fixed, but anyway, we'll see.

Here is my test page: http://www.deronsizemore.com/test/index2.html


First thing is that in FireFox, when using the web developer tool and resizing to 800x600 there becomes a horizontal scroll bar. I thought everything would just scrunch up to fit the resolution. In IE when you resize, the navigation on the right hand side, drops below the #content and #middle-content sections.

Second, the green gradient that starts the #secondary div at the bottom, it does not span the full width of the page. It's probably like 96% or something.

and finally third. There is suppse to be my logo in the upper left hand corner of the page. I've got the image set as a background image in the css which is inside the #header div. Although, nothing I do makes this image show up.

Thanks in advance
deronsizemore is offline   Reply With Quote

Old 06-06-2006, 09:23 PM   #2
agua
Senior Member
 
agua's Avatar
 
Join Date: Sep 2005
Location: Pottsville, NSW
Posts: 528
All my answers are only tested in Firefox - I have no IE at the mo

Firstly:
All your layour divs have % specified - whereas your "#navigation div ul li a" has 190px specified - I changed this to width: 450% and it nearly fixed it - so I think it is because you are using a mixture of px and % - play about with this and it will fix it.

Second:
Putting
Code:
 margin:0;
on your body css should fix your green gradient (its does in FF anyway) - If using 100% of the screen - I always put magin:0; & padding:0; on the css body.

Third:
remove the slash before images - the url is incorrect - I also put in a background color incase any user specifies their own
Code:
background:#fff url(images/logo.gif) no-repeat left center;
__________________
I Do Website Design - but I am here to learn all about publishing
agua is offline   Reply With Quote
Old 06-06-2006, 10:19 PM   #3
deronsizemore
Senior Member
 
deronsizemore's Avatar
 
Join Date: Sep 2005
Posts: 981
Quote:
Originally Posted by agua
All my answers are only tested in Firefox - I have no IE at the mo

Firstly:
All your layour divs have % specified - whereas your "#navigation div ul li a" has 190px specified - I changed this to width: 450% and it nearly fixed it - so I think it is because you are using a mixture of px and % - play about with this and it will fix it.

Second:
Putting
Code:
 margin:0;
on your body css should fix your green gradient (its does in FF anyway) - If using 100% of the screen - I always put magin:0; & padding:0; on the css body.

Third:
remove the slash before images - the url is incorrect - I also put in a background color incase any user specifies their own
Code:
background:#fff url(images/logo.gif) no-repeat left center;

Thanks for the second and third fixes! Worked perfect. I could have sworn I tried "removing the slash" and it did nothing. Oh well..works now.

As for the first issue. I'm not quite understanding you with making width: 450%. That stretches it WAY out and still has scroll bars horizontally at 800x600. I assumed you may have mean 150% instead of 450%, but that was a no go also. Still horizontal scroll.

ideas?
deronsizemore is offline   Reply With Quote
Old 06-06-2006, 10:28 PM   #4
agua
Senior Member
 
agua's Avatar
 
Join Date: Sep 2005
Location: Pottsville, NSW
Posts: 528
Well on Firefox on my computer - it stretched out to the right using 450% - I didn't really understand that neither.

What I was mainly getting at is that to make this perfect - you should either go with pixels or percent - not both as it seems to confuse the width if they are mixed.

For example main-body has a width of 80% whereas your navigation has a width of 190px - so I believe the browser will position main body at, lets say 80% of the screen size (I know you have another div - this is just an example) - but this means that the remaining 20% of the screen maybe smaller than 190px - giving you horizontal scrolling.

Does that make more sense?
__________________
I Do Website Design - but I am here to learn all about publishing
agua is offline   Reply With Quote
Old 06-06-2006, 10:32 PM   #5
agua
Senior Member
 
agua's Avatar
 
Join Date: Sep 2005
Location: Pottsville, NSW
Posts: 528
How about trying this for your navigation:
Code:
#navigation {
float: right;
width: 20%;
}
#navigation div{
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: medium;
width: 100%;
padding: 0px;
margin: 0px;
}
#navigation div ul {
list-style: none;
margin: 0px;
padding: 0px;
border: none;
}
#navigation div ul li {
margin: 0px;
padding: 0px;
}
#navigation div ul li a {
font-size: 80%;
display: block;
border-bottom: 1px dotted #cccccc;
padding: 5px 0px 2px 4px;
text-decoration: none;
color: #3080cb;
}
#navigation div ul li a:hover, #vertmenu ul li a:focus {
color: #000;
background-color: #eeeeee;
}
__________________
I Do Website Design - but I am here to learn all about publishing
agua is offline   Reply With Quote
Old 06-06-2006, 11:02 PM   #6
KelliShaver
Registered
 
Join Date: Apr 2006
Posts: 184
Yes, you have about 3x more CSS on the navigation than you need....
KelliShaver is offline   Reply With Quote
Old 06-07-2006, 12:04 AM   #7
Cutter
Website Developer
 
Join Date: Oct 2004
Posts: 1,612
This CSS layout stuff is what always gets me, especially when its fluid!
__________________
Make more money - Read my Web Publishing Blog
Cutter is offline   Reply With Quote
Old 06-07-2006, 06:31 AM   #8
deronsizemore
Senior Member
 
deronsizemore's Avatar
 
Join Date: Sep 2005
Posts: 981
Quote:
Originally Posted by agua
How about trying this for your navigation:
Code:
#navigation {
float: right;
width: 20%;
}
#navigation div{
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: medium;
width: 100%;
padding: 0px;
margin: 0px;
}
#navigation div ul {
list-style: none;
margin: 0px;
padding: 0px;
border: none;
}
#navigation div ul li {
margin: 0px;
padding: 0px;
}
#navigation div ul li a {
font-size: 80%;
display: block;
border-bottom: 1px dotted #cccccc;
padding: 5px 0px 2px 4px;
text-decoration: none;
color: #3080cb;
}
#navigation div ul li a:hover, #vertmenu ul li a:focus {
color: #000;
background-color: #eeeeee;
}

Still a no go on that code. That was one of the first things I tried (putting width of navigation div to 100%).

It's like I know the problem lies with the navigation, but nothing I change seems to have an affect on the horizontal scroll when resolution is resized.

Thanks
deronsizemore is offline   Reply With Quote
Old 06-07-2006, 06:50 AM   #9
deronsizemore
Senior Member
 
deronsizemore's Avatar
 
Join Date: Sep 2005
Posts: 981
UPDATE: Well I might have figured it out. All I did was change min-width to 750px instead of 780px and it works perfect. I was under the impression that for a site to work in 800x600 the max you could make the width is 780px?

EDIT: Well now that I made that change, it's mucked up in IE. lol.

Last edited by deronsizemore; 06-07-2006 at 07:53 AM.
deronsizemore is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
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

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
PHP cookie/sessions expertise wanted small job/good pay LuckyShima The Marketplace 2 02-09-2006 01:26 AM
Certain site layout better for advertising? deronsizemore Advertising & Affiliate Programs 15 10-12-2005 02:18 AM
New Ruthsarian CSS Layout shim HTML, CSS, Layout, and Design 12 06-06-2005 04:44 PM
Football Site Layout hayesb26 User Owned Websites 4 04-22-2004 01:36 PM
Legal issues with site MattM Business and Legal Issues 2 03-21-2004 07:25 PM



All times are GMT -7. The time now is 10:16 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
Site Copyright © 2003-2006 Jalic Inc. All rights reserved.