- From: Jon Kerny <jon.kerny@gmail.com>
- Date: Tue, 10 May 2016 21:49:29 +0200
- To: www-voice@w3.org
- Message-ID: <CAC5YMgGePCgcY20too73AW98001pquMKJeJKQNBLKnXdFgUFoA@mail.gmail.com>
Hi, I have now almost completed the support of both ecmascript and xpath data models, and I have two more questions/comments. In the xpath xsl I think there is missing single quotes in the template <xsl:template match="//@conf:messageBodyEquals"> <xsl:attribute name="cond"> contains($_event/raw, <xsl:value-of select="."/> ) </xsl:attribute> </xsl:template> I think it should be <xsl:template match="//@conf:messageBodyEquals"> <xsl:attribute name="cond"> contains($_event/raw, '<xsl:value-of select="."/>' ) </xsl:attribute> </xsl:template> And I also have a question on the ecmascript testcases 557 and 561, they contain the condition cond="var1.getElementsByTagName('book')[0].getAttribute('title') == 'title1'" I wonder if this isn't strictly following the specifications. Shouldn't it be cond="var1.getElementsByTagName('book').item(0).getAttribute('title') == 'title1'" I don't think the indexer is part of the specification: https://www.w3.org/TR/DOM-Level-2-Core/core.html#ID-A6C9094 https://www.w3.org/TR/DOM-Level-2-Core/core.html#ID-536297177 https://www.w3.org/2003/01/dom2-javadoc/org/w3c/dom/NodeList.html https://developer.mozilla.org/en-US/docs/Web/API/HTMLCollection That said, I think it's common in implementations. I.e. w3schools includes it in the examples http://www.w3schools.com/jsref/met_element_getelementsbytagname.asp Best regards, Jon
Received on Tuesday, 10 May 2016 20:16:17 UTC