Reputation: 699
Wikipedia's example of XHTML-MP:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.1//EN"
"http://www.openmobilealliance.org/tech/DTD/xhtml-mobile11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>Hello</title>
</head>
<body>
<p>Hello <a href="http://example.org/">world</a>.</p>
</body>
</html>
This fails W3C validation with the error Input is not proper UTF-8, indicate encoding ! Bytes: 0xA9 0x20 0x32 0x30
Even if you add <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
and tell the validator it's UTF8, it gives this error.
If the XHTML-MP DOCTYPE is removed, it works fine. What is the deal?
Upvotes: 0
Views: 1618
Reputation: 5672
http://mobiready.com/launch.jsp?locale=en_EN validates it fine. Wierd
Also you don't need to use 1.1 in order to use JavaScript. Although it wouldn't validate on W3's checker,
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.0//EN" "http://www.wapforum.org/DTD/xhtml-mobile10.dtd">
works just fine with almost all JavaScript supported phones.
Upvotes: 0
Reputation: 25775
The problem is with the external DTD. If you change the DOCTYPE to this, it validates:
<!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.0//EN"
"http://www.wapforum.org/DTD/xhtml-mobile10.dtd">
Upvotes: 1