Webpage view is let aligned on internet explorer yet ok on firefox

Please could you help me, my website has just been loaded and is viewing ok on firefox yet left aligned on internet explorer, how can I fix this

Hi KimTabori. Please post a link to the site so we can have a look. There are lots of possible reasons for this, but perhpas most likely is that you don’t have a doctype.

My web address is www.mumsdiary.co.za there are 3 errors I have picked up that show fine on firefox yet incorrect on internet explorer:

  1. view left aligned
  2. drop down menu’s show under the banner
  3. Job Listings “view full list” drops down to the bottom of the page

Your help would me most appreciated

Kind regards Kim

Below is a copy of my file for the template, I added the doctype as per your suggestion a few days ago but still no luck…perhaps you can see what needs to be added/changed, many thanks Kim:)

<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Strict//EN” “http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd”>
<html xmlns=“http://www.w3.org/1999/xhtml” lang=“en” xml:lang=“en”>

<head>
<jdoc:include type=“head” />
<title><?php echo $mainframe->getCfg(‘sitename’);?></title>
<meta http-equiv=“content-type” content=“text/html; charset=utf-8” />
<link rel=“stylesheet” href=“templates/<?php echo $this->template ?>/css/template.css” type=“text/css” />
<link rel=“stylesheet” href=“templates/<?php echo $this->template ?>/css/<?php echo $this->params->get(‘colorVariation’); ?>.css” type=“text/css” />
<link rel=“stylesheet” href=“templates/<?php echo $this->template ?>/css/<?php echo $this->params->get(‘backgroundVariation’); ?>_bg.css” type=“text/css” />
</head>

<body id=“page_bg” class=“color_<?php echo $this->params->get(‘colorVariation’); ?> bg_<?php echo $this->params->get(‘backgroundVariation’); ?> width_<?php echo $this->params->get(‘widthStyle’); ?>”>

<div class=“left” id=“wrapper”>
<!–menu begins–>
<div class=“clear” id=“menucontainer”>
<div id=“mmenu”><jdoc:include type=“modules” name=“mmenu” /></div>
</div>
<!–menu ends–>

&lt;!--header begins--&gt;
&lt;div id="headercontainer"&gt;
	&lt;div id="headerimage"&gt;
		&lt;div id="header"&gt;
			&lt;div id="logobar"&gt;
				&lt;a href="index.php" class="fleft" id="logo"&gt;SUNFLOWER&lt;/a&gt;
				&lt;div class="fright" id="search"&gt;&lt;jdoc:include type="modules" name="user4" /&gt;&lt;/div&gt;
			&lt;/div&gt;
			&lt;div class="clear" id="bannercontent"&gt;
				&lt;jdoc:include type="modules" name="user5" style="xhtml" /&gt;
			&lt;/div&gt;
			&lt;jdoc:include type="modules" name="sfbox" /&gt;
		&lt;/div&gt;
	&lt;/div&gt;
&lt;/div&gt;
&lt;!--header ends--&gt;
&lt;div align="center" class="clear" id="ad"&gt;&lt;jdoc:include type="modules" name="banner" /&gt;&lt;/div&gt;
&lt;!--breadcrumbs begins--&gt;
&lt;div class="clear" id="bcrumb"&gt;
	&lt;jdoc:include type="module" name="breadcrumbs" /&gt;
&lt;/div&gt;
&lt;!--breadcrumbs ends--&gt;

<!–content begins–>
<div class=“clear” id=“content”>
<div class=“fleft” id=“leftcol”>
<jdoc:include type=“modules” name=“left” style=“rounded” />
</div>
<?php if($this->countModules(‘left’) and $this->countModules(‘right’) and JRequest::getCmd(‘layout’) != ‘form’) : ?>
<div class=“fleft” id=“maincol”>
<?php elseif($this->countModules(‘left’) and !$this->countModules(‘right’) and JRequest::getCmd(‘layout’) != ‘form’) : ?>
<div class=“fleft” id=“maincolumn_left”>
<?php elseif(!$this->countModules(‘left’) and $this->countModules(‘right’) and JRequest::getCmd(‘layout’) != ‘form’) : ?>
<div class=“fleft” id=“maincolumn_right”>
<?php else: ?>
<div class=“fleft” id=“maincolumn_full”>
<?php endif; ?>
<div class=“nopad”>
<?php
if ($this->countModules(‘user1’) and $this->countModules(‘user2’) and $this->countModules(‘user3’)) {
$width1 = “33%”;
} else if (($this->countModules(‘user1’) and $this->countModules(‘user2’)) or ($this->countModules(‘user1’) and $this->countModules(‘user3’)) or ($this->countModules(‘user2’) and $this->countModules(‘user3’))) {
$width1 = “50%”;
} else {
$width1 = “100%”;
}
?>
<div style=“float:left; width: <?php echo $width1; ?>”><jdoc:include type=“modules” name=“user1” style=“xhtml” /></div>
<div style=“float:left; width: <?php echo $width1; ?>”><jdoc:include type=“modules” name=“user2” style=“xhtml” /></div>
<div style=“float:left; width: <?php echo $width1; ?>”><jdoc:include type=“modules” name=“user3” style=“xhtml” /></div>
<div class=“clear”></div>
<jdoc:include type=“message” />
<jdoc:include type=“component” />
<?php
if ($this->countModules(‘user6’) and $this->countModules(‘user7’) and $this->countModules(‘user8’)) {
$width2 = “33%”;
} else if (($this->countModules(‘user6’) and $this->countModules(‘user7’)) or ($this->countModules(‘user6’) and $this->countModules(‘user8’)) or ($this->countModules(‘user7’) and $this->countModules(‘user8’))) {
$width2 = “50%”;
} else {
$width2 = “100%”;
}
?>
<div style=“float:left; width: <?php echo $width2; ?>”><jdoc:include type=“modules” name=“user6” style=“xhtml” /></div>
<div style=“float:left; width: <?php echo $width2; ?>”><jdoc:include type=“modules” name=“user7” style=“xhtml” /></div>
<div style=“float:left; width: <?php echo $width2; ?>”><jdoc:include type=“modules” name=“user8” style=“xhtml” /></div>
<div class=“clear”></div>
<jdoc:include type=“modules” name=“user9” style=“xhtml” />
</div>
</div>
</div>

<div class=“clear” id=“footercontainer”>
<div id=“footer”>
<?php
$templancrand = rand(0,1);
$templanc = array(“Joomla Templates”,“Free Joomla Templates”);
$templanc = $templanc[$templancrand];
$linkrand = rand(0,10);
$anc = array(
array(“URL” => “”, “ANCHOR” => “Web Hosting”),
array(“URL” => “”, “ANCHOR” => “Reseller Hosting”),
array(“URL” => “”, “ANCHOR” => “VPS Hosting”),
array(“URL” => “”, “ANCHOR” => “Joomla Hosting”),
array(“URL” => “web_hosting.html”, “ANCHOR” => “Web Hosting”),
array(“URL” => “reseller_hosting.html”, “ANCHOR” => “Reseller Hosting”),
array(“URL” => “vps_hosting.html”, “ANCHOR” => “VPS Hosting”),
array(“URL” => “vps_hosting.html”, “ANCHOR” => “VPS Servers”),
array(“URL” => “dedicated_servers.html”, “ANCHOR” => “Dedicated Servers”),
array(“URL” => “dedicated_servers.html”, “ANCHOR” => “Managed Dedicated Servers”),
array(“URL” => “joomla_hosting.html”, “ANCHOR” => “Joomla Hosting”)
);
$url = $anc[$linkrand][“URL”];
$anchor = $anc[$linkrand][“ANCHOR”];
?>
<div class=“fleft”><jdoc:include type=“modules” name=“bottommenu” /></div>
<p class=“fright”><a href=“http://www.buyhttp.com/joomla_templates.html” target=“_blank”><?php echo $templanc; ?></a> by BuyHTTP <a href=“http://www.buyhttp.com/&lt;?php echo $url; ?>” target=“_blank”><?php echo $anchor; ?></a></p>
<p align=“right” class=“clear”><jdoc:include type=“modules” name=“footer” style=“xhtml” /></p>
</div>
</div>
</div>
</div>
</body>
</html>

The online version you linked to above still doesn’t have a doctype, so that’s the first thing to address, as it’s critical. Are you able to make changes to the online version?

I uploaded my website about 10 mins ago, could you have another look please.

Yes I can make changes to the html files, I am working on Joomla and Afrihost

Regards Kim

I still don’t see the change, and I checked in a browser I hadn’t used for your site before. :slight_smile: Something seems to be going wrong with the uploading. How are you trying to do this? Maybe Joomla requires the doctype to be inserted somewhere special. Didn’t I post a link about that recently?

I am using cPanel to upload my files to the www, I am not aware of any special requirements for Joomla.

I don’t know anything about Joomla. But from searching online, I gather the doctype needs to be at the top of your index.php file. Is that what you posted above?

Hi Ralph, yes I pasted it on the top of the template index php file, see my html on earlier post, regards Kim

There’s still no doctype showing up on-line. I’ve tried running your page through the W3C validator and it’s also complaining that it can’t find a doctype, so we definitely have a problem there. Unfortunately, I’ve never used Joomla!, either, so I’m not sure what to suggest next, but Ralph is right - we need to get this fixed in order to deal with other issues.

I’m not sure what to suggest, but if all else fails, you could try this. In cPanel, go to the file manager and find your index.php file. Make sure the file permissions are set so you can write to it, then open it with the code editor. Check that the doctype is correctly displayed there, and edit it if it isn’t. Save the changes.

You guys are awesome…:):):):)I did what you suggested and it did not appear on my file manager on cPanel so I updated it there and it has fixed my problem…I am so grateful, thanks so much

Just one more thing, My articles for my front page are not coming through, all the other links info is fine yet the articles (with read more links) seem to have a problem, again this is find on firefox.

Please could you help me here too

Thanks Kim

Hm, tough one. I’m sorry to have to say this, but whatever generated all the code for your page really has done a bad job. Truthfully, the code is a terrible mess, and is a good reason why it’s better to learn to write plain, simple and efficient code by yourself. It seems that the browser is dropping its bundle when it gets to the long conditional code in about the middle, but that code doesn’t deserve to be there anyway. I’m not sure what to suggest really, except perhaps run the code through the validator to see if that picks up the offending glitch. Or perhaps someone with a better eye will pick up what’s causing IE to choke. Sorry I can’t be more help!

Great news, I fixed this one, I deleted the articles and recreated them ensuring I used notepad prior to inserting the articles, Joomla is quite sensitve on this issue, so lesson is that all articles need to be pasted into notepad prior to pasting into the articles/sections/categories

Thanks to all that took the time to help me, what an awesome network we have…