- From: <jaccoud@petrobras.com.br>
- Date: Fri, 9 May 2003 15:58:40 -0300
- To: Dan Connolly <connolly@w3.org>
- Cc: Chris Lilley <chris@w3.org>, Ivan Herman <ivan@w3.org>, w3t@w3.org, w3c-translators@w3.org
>Hmm... that's an interesting idea... what sort of query did >you have in mind? The trick is restricting the check in xml:lang attribute to just the number of characters present in the query. This way, a query to "pt" would return any documents tagged with either "pt", "pt-BR", or "pt-anything". If you go a step further and restrict the test to the minimum number of charaters of either the query string and the testes string, then it would also return "pt" documents when asked for "pt-PT", but not "pt-BR". I think this behaviour is exactly what is expected from xml:lang. This is easy to implement, just tweak the XPath expression in the query using the string-length() and starts-with() functions. ============================================= Marcelo Jaccoud Amaral mailto:jaccoud@petrobras.com.br voice: +55 21 2534-3485 fax: +55 21 2534-1809 ============================================= There are only 10 kinds of people in the world: those who understand binary and those who don't.
Received on Friday, 9 May 2003 15:06:56 UTC