My quest for XHTML validation continues! I found a strange issue about
links. The http://validator.w3.org showed many errors like the
following:

----------
an attribute specification must start with a name or name token.

<a href='http://boltwire.com''XXXXclass='external' hreflang='en'
title='Gestor de...

An attribute name (and some attribute values) must start with one of a
restricted set of characters. This error usually indicates that you
have failed to add a closing quotation mark on a previous attribute
value (so the attribute value looks like the start of a new attribute)
or have used an attribute that is not defined (usually a typo in a
common attribute name).
----------

I marked for you, with "XXXX", the place where the validator found an
invisible spurious character. After severals debugging changes, I
found the solution seems to change the last line of BOLTMlinks (in
barn/scripts/markups.php) like the following:

return BOLTescape('<a href="' . $link . '" ' . $defaultAttr . $attr .
'>' . BOLTtranslate($label) . "$missingPage</a>");

You see, I swapped single for double quotes in href and added a space
before defaultAttr. I can use single or double quotes in the
defaultAttr's content, it makes no difference. Now all validation
errors are gone!

Don't ask me why the quotes swapping and one additional space fixed
this problem (additional spaces alone or only quotes swapping made no
difference!). I really don't understand, but it works. Some XHTML
expert out there? Any clue? Maybe a bug in the validator itself?

By the way, is anyone else validating BoltWire sites? I think this
"quest" is necessary to make BoltWire suitable for professional sites.

Cheers,
Marcos

--
http://alinome.net
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"BoltWire" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/boltwire?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to