|
|
#1 | |
|
hooah
|
I'm making a website for my ROTC at my college and I'm using CSS. I have a menu bar on the left and a content section on the right. They are in two separate div's and i'm trying to get them to match up at the bottom.
the menu div stops halfway because the menu doesn't go down all the way. so i set the height to a percentage to try and match up with the content section. (or exact height they're both screwed up) so here's the two images: firefox: ![]() IE: ![]() as you can see there's a difference and I can't figure out how to make them match. any ideas? EDIT: http://people.rit.edu/~ijs4097/rotc/ View it in firefox and then IE and see the huge difference. I usually just throw everything in tables and it works perfectly. guaranteed. no questions asked, no matter what browser. But I used div's this time because they're supposedly so much better and it's just working great so far as you can tell. I really see the reason to switch over...
__________________
Main Rig: Secondary Rig: FX-60, 7900GTX, 2 x 1BG OCZ Platinum, A8N32-SLI Deluxe, Antec 180, XP x32 |
|
|
|
|
|
|
#2 | |
|
Registered User
Join Date: Mar 2004
Posts: 15,486
|
yea ive had this problem before as well. check your IE code really carefully. if you can fix it in IE it will be fixed in FF when you copy/paste the code. IE is much more sensitive to mistakes than FF is.
i suggest using Web Developer Tools Add-On for Firefox. it will display any errors you have in HTML/CSS and any warnings. once again, if you fix it in IE, in my experience, the problem will be resolved in FF as well. |
|
|
|
|
|
|
#3 |
|
hooah
|
hmm. I have both my CSS and my HTML validated without errors. (there's 4 errors on the HTML page but thats because it doesn't like the way the flash is put in)
so difficult...
__________________
Main Rig: Secondary Rig: FX-60, 7900GTX, 2 x 1BG OCZ Platinum, A8N32-SLI Deluxe, Antec 180, XP x32 |
|
|
|
|
|
#4 | |
|
Ngemu Mod
Join Date: Jul 2003
Location: Fresno, CA
Posts: 1,886
|
Do you have an outer div around the 2 divs? Try creating an outer div with an exact height and width. Then put those 2 divs inside that div and set their heights to 100%.
__________________
[i7 2600k @4.4ghertz][2x4 GB DDR3 1600][EVGA GTX570 1.280GB SC][EVGA GTX460 physx][Asrock Extreme7 Gen3 Z68][2xSeagate 160 Gb SATA HD raid0][Seagate 250 GB SATA2 HD][Sony Bravia 40' 1080p LCD HDTV][NEC 3520a DVD+-DLw][Windows 7 Ultimate x64][Rosewill 1000w] |
|
|
|
|
|
|
#5 |
|
hooah
|
That's still not going to work because IE include padding in the pixel count while Firefox doesn't. So i still end up with the mismatched bottoms.
__________________
Main Rig: Secondary Rig: FX-60, 7900GTX, 2 x 1BG OCZ Platinum, A8N32-SLI Deluxe, Antec 180, XP x32 |
|
|
|
|
|
#6 | |
|
plenty of work, no games
Join Date: Sep 2007
Posts: 559
|
Probably the easiest solution that will work in IE6, IE7, IE8, FF, Opera and Safari is to use background-image with dark-gray bar on #bottom div. Its height can be 1px only (thus very small), and use "repeat-y" on that background.
#bottom { background: white url(background.gif) top left repeat-y; } Also #footer should be within this DIV, having "clear:both" property set.
__________________
Q9550@3.4 + Asus P5Q Premium + 16GB RAM + 2xVelociraptor 300GB + 4xWD Black 1TB RAID-5 on Adaptec 5805 + PoV GTX580 + Dell 3008WFP + Windows 7 x64 Xbox 360 Elite + Kinect + Onkyo receiver + Acoustic Energy Aelite 1/3/center speakers + 46" FullHD Samsung TV |
|
|
|
|
|
|
#7 | |
|
Registered User
Join Date: Mar 2004
Posts: 15,486
|
Quote:
|
|
|
|
|
|
|
#8 |
|
hooah
|
i decided against that since it's not very flexible.
http://people.rit.edu/~ijs4097/rotc/ that's it at the moment. the only problem is that when you shrink the window the header goes over. So my two options are to not have the gray bar on the left go all the way down and the footer will stop with 10px from the bottom of the center column and the page becomes scrollable. OR the gray bar (for the menu) goes all the way down and the footer goes over everything and i lose the text below it. and we got rid of tables for this.....makes sense to me EDIT: both my CSS and html are completely validated btw EDIT: i went with your background image thing and it's working fine so far. thanks for the advice!
__________________
Main Rig: Secondary Rig: FX-60, 7900GTX, 2 x 1BG OCZ Platinum, A8N32-SLI Deluxe, Antec 180, XP x32 |
|
|
|
![]() |
| Thread Tools | |
|
|