Uutiset:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu
Advertisement:

Internet Exploder v Firefox and <center>

Aloittaja Moif, elokuu 10, 2006, 10:50:39 AP

« edellinen - seuraava »

Moif

Hello,

I'm very confused. I've been trying for a couple of days now to get my forum logo to sit atop my forums and to stay there no matter the screen resolution. Well I managed to crack it but now a new problem has arisen.

What I want to achieve is have my forum a fixed width of 1024, centered and with the text left aligned. I've managed to pull it off using the modifications in This Post but Internet Explorer doesn't like it and all the text is centered. So I've had to revert back to a left aligned forum.

What I've discovered is that the forum is split up into different sections. I've been able to centre the bit with the greeting on and get rid of the search box but that still leaves the part with the main content. I placed it all in a table of 1024 width as follows:


// The main content should go here.

echo '


<table width="1024">
<td>
<div id="bodyarea" style="padding: 1ex 0px 2ex 0px;">';



}

function template_main_below()

{

global $context, $settings, $options, $scripturl, $txt;



echo '

</div>
</td>
</table>';


So my problem is if I <div> the whole forum it's fine in Firefox but not in IE.

Please can someone help? My index.template is here: http://www.titan-guild.co.uk/files/index.template.txt and my css is here: http://www.titan-guild.co.uk/files/style.css

thank you



Moif

#1
RIGHT THEN!

Bloody thing. Instead of using the div trick I replaced it with a table :) Don't know why I didn't think of this before.



bloc

Using margin: auto; on a div would probably have solved it. ;)

Advertisement: