Hi Karl,

An interesting piece, well done. However, it still leaves me with some confusion.

I have been using Neil Crosby's PHP approach on [1] (see signature, below) and it works 'OK', BUT, if I omit the meta tag:

<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=utf-8" />

from it's usual place, I get Chinese characters everywhere. In other words, although the PHP header puts the lang attribute and utf-8 in the code, it won't work without the meta as well. (Not for me, anyway :-)

Why is this, do you think?

Using the PHP approach, the head section appears as follows (stars to highlight the offending meta tag) :

<?xml version='1.0' encoding='utf-8' ?>
<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.1//EN' 'http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd'>
     <html xmlns='http://www.w3.org/1999/xhtml' xml:lang='en'><head>
<title>gwelanmor internet</title>
<meta name="Keywords"
       content=" web design, flash, CSS, web standards, affordable style, minimalist, 
innovative, Cornwall, U.K." />
<meta name="Description"
       content=" gwelanmor Internet is a company which specialises in creating 
modern,standards-based, minimalist web sites at affordable rates" />
<meta content="Bob McClelland"
       name="author" />
<meta content="bob mcclelland, gwelanmor-internet"
       name="Copyright" />
<meta http-equiv="Content-Type" 
********************************************************************************
       content="application/xhtml+xml; charset=utf-8" />
<link href="opening/opening.css"
       rel="stylesheet"
       type="text/css" />
</head>

Or, if IE or any browser that won't serve application/xhtml+xml, it appears as:

<!DOCTYPE HTML PUBLIC '-//W3C//DTD HTML 4.01//EN' 'http://www.w3.org/TR/html4/strict.dtd'>
     <html lang='en'><head>
<title>gwelanmor internet</title>
<meta name="Keywords"
       content= "web design, flash, CSS, web standards, affordable style, minimalist, 
innovative, Cornwall, U.K.">
<meta name="Description"
       content= "gwelanmor Internet is a company which specialises in creating 
modern,standards-based, minimalist web sites at affordable rates">
<meta content="Bob McClelland"
       name="author">
<meta content="bob mcclelland, gwelanmor-internet"
       name="Copyright">
<meta http-equiv="Content-Type" 
*****************************************************************************************************
       content="application/xhtml+xml; charset=utf-8">
<link href="opening/opening.css"
       rel="stylesheet"
       type="text/css">
</head>

Obviously, the meta tag in the IE example is simply wrong and I've wondered about using PHP to generate the line as appropriate so this 'daft' line doesn't appear. But it doesn't seem to work without the charset. This is why I asked yesterday about using :

<meta http-equiv="Content-Type" content="charset=utf-8" />

Lachlan says this is simply incorrect, so I'm a bit confused by all this.

--
Best Regards,

Bob McClelland

Cornwall (UK)
www.gwelanmor-internet.co.uk [1]





Karl Dawson wrote:

Hi,

Apologies in advance if you see this cross-posted:

"From the Top" is a series of articles that I am publishing to concisely explain how and why to construct a high quality, web-standards compliant head section for a web page. The second article, just released, examines MIME and Content Negotiation.

http://www.thatstandardsguy.co.uk/2006/01/16/content-negotiation/

Comments, especially error-spotting and general "bravo" very welcome, it all helps with my work position.

Regards,
--
Karl Dawson
Crusader for Web Standards and Accessibility
http://www.thatstandardsguy.co.uk
--------------------------------------------------
Accessites Team Member - http://www.accessites.org/
--------------------------------------------------

"The power of the Web is in its universality. Access by everyone regardless of disability is an essential aspect."
Tim Berners-Lee - W3C Director and inventor of the World Wide Web


--
Best Regards,

Bob McClelland

Cornwall (UK)
www.gwelanmor-internet.co.uk


******************************************************
The discussion list for  http://webstandardsgroup.org/

See http://webstandardsgroup.org/mail/guidelines.cfm
for some hints on posting to the list & getting help
******************************************************

Reply via email to