PDA

View Full Version : FF and Chrome Display Page OK But Not IE


grungefreak
06-09-2010, 10:02 PM
Can somebody please help with this. I developed an online learning tutorial in Chrome. I just checked it in firefox and chrome and it's fine. But IE is not displaying as it should. If anybody could help that would be great.

Here's the link:
http://hanlonthesis.com/lesson1_webdev.php
GF

edbr
06-10-2010, 02:46 AM
Page Access logged and
<!-- Web Page Design by James Koster - http://www.jameskoster.co.uk -->

these are messing with the doctype move them or delete them and see if that clears it up

grungefreak
06-10-2010, 03:45 PM
Page Access logged and
<!-- Web Page Design by James Koster - http://www.jameskoster.co.uk -->

these are messing with the doctype move them or delete them and see if that clears it up

Removing those makes no diff. The "web page design...." is only a html comment. The other one "Page Access Logged" is run from a php script but makes no diff when I remove it.

GF

Corrosive
06-10-2010, 06:04 PM
From W3;

Does Microsoft Internet Explorer accept the media type application/xhtml+xml?

No. However, there is a trick that allows you to serve XHTML1.0 documents to Internet Explorer as application/xml.

Include at the top of your document the line in bold here:

<?xml version="1.0" encoding="iso-8859-1"?>
<?xml-stylesheet type="text/xsl" href="copy.xsl"?>
<!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">
<head>
where copy.xsl is a file that contains the following:

<stylesheet version="1.0"
xmlns="http://www.w3.org/1999/XSL/Transform">
<template match="/">
<copy-of select="."/>
</template>
</stylesheet>
Note that this file must be on the same site as the document referring to it.

Although you are serving the document as XML, and it gets parsed as XML, the browser thinks it has received text/html, and so your XHTML 1.0 document must follow many of the guidelines for serving to legacy browsers.

Your XHTML document will continue to work on browsers that accept XHTML 1.0 as application/xml.

You also should not have anything before your doctype declaration yet you seem to have 'Page Access logged' up there.

edbr
06-11-2010, 02:54 AM
the warnings errors returned are below

Result: 0 errors / 13 warnings

line 1 column 5 - Warning: missing <!DOCTYPE> declaration
line 1 column 5 - Warning: plain text isn't allowed in <head> elements
line 1 column 5 - Info: <head> previously mentioned
line 1 column 5 - Warning: inserting implicit <body>
line 1 column 5 - Warning: <!DOCTYPE> isn't allowed after elements
line 3 column 1 - Warning: discarding unexpected <html>
line 9 column 1 - Warning: <head> isn't allowed in <body> elements
line 1 column 5 - Info: <body> previously mentioned
line 10 column 1 - Warning: <meta> isn't allowed in <body> elements
line 1 column 5 - Info: <body> previously mentioned
line 11 column 1 - Warning: <title> isn't allowed in <body> elements
line 1 column 5 - Info: <body> previously mentioned
line 12 column 1 - Warning: <link> isn't allowed in <body> elements
line 1 column 5 - Info: <body> previously mentioned
line 13 column 1 - Warning: </head> isn't allowed in <body> elements
line 1 column 5 - Info: <body> previously mentioned
line 15 column 1 - Warning: discarding unexpected <body>
line 74 column 8 - Warning: inserting implicit <p>
line 74 column 8 - Warning: trimming empty <p>
Info: Doctype given is "-//W3C//DTD XHTML 1.0 Transitional//EN"
Info: Document content looks like XHTML 1.0 Transitional

which is why the text before the doctype seems to through all out of kilter