$WBGETXML is available for use with all WBSP commands.


Source - Either Internet address of the XML file you want to include in your page (URL) or a string value containing XML code. URL can be either absolute (containing entire address including protocol, server, path and resource) or relative (to document root of virtual server if it starts with slash / character, or to the directory where the WBSP file is located). XML source code must start with "<?xml" (without quotations)
ArrName - name that will be used as prefix for all variables where XML node values will be stored.
NodeName - Name of the parent node for which all child nodes will be retrieved
limit - optional parameter. Contains the number of items to be included in arrays
show - optional parameter  - if set to true (T,ON,1) WhizBase will show the last index (length-1) of resulting array

Set of arrays containing values of all child nodes of NodeName of as well as array containing all the parent node (NodeName) values (all child nodes in one line separated by space). Arrays are named following this convention: ArrName_NodeName() and ArrName_NodeName_ChildNodeName(). See the example.


No.: $wbgetv[loopcounter]<br/>
Condition (full parent node): <b>$wbgetv[conditions_condition($wbgetv[loopcounter])]</b><br/>
Code: $wbgetv[conditions_condition_code($wbgetv[loopcounter])]<br/>
Day_Icon: $wbgetv[conditions_condition_day_icon($wbgetv[loopcounter])]<br/>
Night_Icon: $wbgetv[conditions_condition_night_icon($wbgetv[loopcounter])]<br/>
Description: $wbgetv[conditions_condition_description($wbgetv[loopcounter])]<br/>

File XMLSample.xml

<?xml version="1.0" encoding="UTF-8"?>
    <description>XXX description</description>
    <description>YYY description</description>
    <description>ZZZ description</description>

After running this example, the resulting page in browser should look like this:

No.: 0
Condition (full parent node): XXX XXX description XXXDayIcon.png XXXNightIcon.png
Code: XXX
Day_Icon: XXXDayIcon.png
Night_Icon: XXXNightIcon.png
Description: XXX description
No.: 1
Condition (full parent node): YYY YYY description DayYYYIcon.png NightYYYIcon.png
Code: YYY
Day_Icon: DayYYYIcon.png
Night_Icon: NightYYYIcon.png
Description: YYY description
No.: 2
Condition (full parent node): ZZZ ZZZ description DayIconZZZ.png NightIconZZZ.png
Code: ZZZ
Day_Icon: DayIconZZZ.png
Night_Icon: NightIconZZZ.png
Description: ZZZ description