Thanks a lot,
After your confirmation I've overcome it eventually.
Yes, I tried it with correct syntax originally as well, but the problem was that I received the following structure
Code:
path = {
item,
length: 1,
_newEnum {...}
}
as an argument of my object's method whereas I expected just a plain string will be passed as a parameter of xslObj:add() method in the following code:
Code:
xsl
...
<xsl:variable name="path" select="@path" />
<xsl:variable name="index" select="xslObj:add($path)" />
...
javascript
myObject.prototype.add = function(path) {
...
}
And only after your answer I guessed (better later than never) to enumerate an argument and got path[0] was my desired parameter and it is not a string but a full-fledged attribute node (path[0].nodeType == 2) from my transformed xml document.
So in xslObj:add($path) - $path is a nodelist. Should I have expected it this way considering my code above?
Thank you once again and excuse my terrible English.