W3C home > Mailing lists > Public > public-mobileok-checker@w3.org > July 2007

F2F demo: html / xhtml namespace

From: Roland Gülle <roland@7val.com>
Date: Wed, 18 Jul 2007 16:20:38 +0200
Message-Id: <6ED36CA9-2E0E-4B92-A5AD-E6B12BBBE5AC@7val.com>
To: public-mobileok-checker <public-mobileok-checker@w3.org>

The google page hat an empty namespace,
so we get the result:
...
   <docContent>
      <html xmlns="">
...

With this structure, none of our //html:* xpath matches,
because we use a namespace for the html doc:
xmlns:html="http://www.w3.org/1999/xhtml"

The first simple solution could be another check if:
//docContent/html:html/html:body
is available.

But this is not the solution.

A doc structure:
<html xmlns:html="http://www.w3.org/1999/xhtml">
  ...
  <body>
   <table>
    <tr>
     <td>
      <table xmlns="">
         ...
returns a valid nested table test (same with all other document xpath  
checks).

Some possible solutions:
* remove all namespaces from the document in the preprocessor
or
* check all xpath with local name
or
* define rules at the BP about namespaces
(and check them in a checkertest)

Cheers,
  Roland
Received on Wednesday, 18 July 2007 14:22:04 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:13:03 GMT