I am trying to use xpath to set the max length of a control on a browser form.
a) i cant get the maxlength attribute set, and
b) I am sure that a for each when I know that there is one node is not the way to go!
any clues / pointers appreciated
K
Code:
<input type="text" name="txtPostcode" id="txtPostcode">
<xsl:for-each select="document('[URL unfurl="true"]http://localhost/xmlproject/bdefinitions.xsd')/xs:schema/xs:simpleType[/URL][@name='postcodetype']//xs:length">
<maxlength value="{@value}"/>
</xsl:for-each>
</input>
a) i cant get the maxlength attribute set, and
b) I am sure that a for each when I know that there is one node is not the way to go!
any clues / pointers appreciated
K