Lasso Soft Inc. > Home

[ xml_nodeList->item ]


The [xml_nodeList->item] method returns an element from an xml_nodeList object. The method requires one parameter which is the integer index of the element to be returned. 

Note: Unlike Lasso™ array objects, xml_nodeLists are 0 indexed. ie. to return the first element of the list use xml_nodeList->item( 0 ).

  • Syntax
xml_nodeList->item( index )
  • Beginner

Return an element from an xml_nodeList

Use the [xml_nodeList->item]  method.

This example retrieves the "date" node of the 3rd Monday from a list of dates stored in an xml document.

Note: whitespace is included in the xml snippet for readability only.


var( aMonth = xml('<weekday day="Monday">
                  </weekday>') )

var( mondays = $aMonth->childNodes )




Recent Comments

No Comments found

Please note that periodically LassoSoft will go through the notes and may incorporate information from them into the documentation. Any submission here gives LassoSoft a non-exclusive license and will be made available in various formats to the Lasso community.

LassoSoft Inc. > Home



©LassoSoft Inc 2015 | Web Development by Treefrog Inc | PrivacyLegal terms and Shipping | Contact LassoSoft