CSS issue
|
dc2447
Joined: 2002-09-22
Posts: 130 |
Posted: Sun, 2005-10-09 16:53
|
|
Hi - I am getting ready to switch to G2 but I am fighting with the CSS. I am using the blue colorpack modified with matrix theme. Thew issue is my header: How my g2 looks How the header *should* look Any idea why the table is getting stretched like that? cheers |
|

Posts: 130
anyone? Maybe I'm not being clear. Somehow one of the style sheets in G2 is causing my header to look like this:
when it should look like this:
This is the only thing stopping me 'living' my g2
Posts: 383
In IE everything looks more or less correct...
Can you check the padding and margins of that image and the table cell around it?
by the way, an easier way to get that look would be without tables. I will show you another way which is not correct either but already is a lot better:
<div style="padding: 0; width: 95%"> <div style="background-color: #efefef; text-align: center;"> <a style="font-weight: bold;" href="http://www.cpfc.org">Home</a> | <a style="font-weight: bold;" href="http://forums.cpfc.org/chat.php">Chat</a> | <a style="font-weight: bold;" href="http://forums.cpfc.org">Forums</a> | <a style="font-weight: bold;" href="http://gallery.cpfc.org">Gallery</a> | <a style="font-weight: bold;" href="http://links.cpfc.org">Links</a> | <a style="font-weight: bold;" href="http://news.cpfc.org">News Feeds</a> | <a style="font-weight: bold;" href="http://league.cpfc.org">Predictions</a> | <a style="font-weight: bold;" href="http://travel.cpfc.org">Travel</a> </div> <div style="margin: 0; padding: 0; height: 0; line-height: 0; border-top: 4px solid #f00; border-bottom: 3px solid #00f;"> </div> </div>If you decide not to use this code, at least look at this part
In this part of code is no text not even a link, this will display nothing and looks like the result of a wysiwyg editor...
(btw: the font, b and center elements should not be used anymore in any case)
______________________
I made a theme for G2, try it
Posts: 130
Thanks - with a bit of tweaking that works great
Posts: 383
Actually, you used the original version of my reply, I edited it because the thing you are using now doesn't work correctly in IE. The thing I put above now works in both browsers. I noticed the changes, and you changed it the wrong way! Below is a version that is more correct:
<div style="text-align: center;"> <div style="padding: 0; width: 95%"> <div style="background-color: #efefef; text-align: center;"> <a style="font-weight: bold; font-size: small;" href="http://www.cpfc.org">Home</a> | <a style="font-weight: bold; font-size: small;" href="http://forums.cpfc.org/chat.php">Chat</a> | <a style="font-weight: bold; font-size: small;" href="http://forums.cpfc.org">Forums</a> | <a style="font-weight: bold; font-size: small;" href="http://gallery.cpfc.org">Gallery</a> | <a style="font-weight: bold; font-size: small;" href="http://links.cpfc.org">Links</a> | <a style="font-weight: bold; font-size: small;" href="http://news.cpfc.org">News Feeds</a> | <a style="font-weight: bold; font-size: small;" href="http://league.cpfc.org">Predictions</a> | <a style="font-weight: bold; font-size: small;" href="http://travel.cpfc.org">Travel</a> </div> <div style="margin: 0; padding: 0; height: 0; line-height: 0; border-top: 4px solid #f00; border-bottom: 3px solid #00f;"> </div> </div> </div>The align attribute is also deprecated, so are most attributes you use inside tables!! You should solve this using css...
______________________
I made a theme for G2, try it
Posts: 130
This code aligns left in firefox - no idea about MSIE
Posts: 383
Actually, that is a bug in Firefox, I forgot about that, the code below includes the fix for the bug so it works in both browsers!
<div style="text-align: center;"> <div style="padding: 0; width: 95%; margin: 0 auto;"> <div style="background-color: #efefef; text-align: center;"> <a style="font-weight: bold; font-size: small;" href="http://www.cpfc.org">Home</a> | <a style="font-weight: bold; font-size: small;" href="http://forums.cpfc.org/chat.php">Chat</a> | <a style="font-weight: bold; font-size: small;" href="http://forums.cpfc.org">Forums</a> | <a style="font-weight: bold; font-size: small;" href="http://gallery.cpfc.org">Gallery</a> | <a style="font-weight: bold; font-size: small;" href="http://links.cpfc.org">Links</a> | <a style="font-weight: bold; font-size: small;" href="http://news.cpfc.org">News Feeds</a> | <a style="font-weight: bold; font-size: small;" href="http://league.cpfc.org">Predictions</a> | <a style="font-weight: bold; font-size: small;" href="http://travel.cpfc.org">Travel</a> </div> <div style="margin: 0; padding: 0; height: 0; line-height: 0; border-top: 4px solid #f00; border-bottom: 3px solid #00f;"> </div> </div> </div>I actually tested it this time ;)
______________________
I made a theme for G2, try it
Posts: 130
wow - very cool - many thanks
Posts: 8
I'm having the same issue. Check out my home page and then my photos page. You can see the difference in the header and footer.
http://www.larryandlisaward.com
Posts: 8
It seems that space is being added to the bottom of my images. I removed some 1 x 1 pixel spacer images and those areas corrected.
Posts: 8
I found the problem that causes this.
Change the line at the top of theme.tpl from:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
to:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">