<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><meta content="text/html;charset=UTF-8" http-equiv="Content-Type"></head><body ><div style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10pt;"><div>Just an FYI to whom it may concern...<br></div><div><br></div><div><br></div><div><br></div><div><br></div><div>I am adding some complexity to the document from this source:<br></div><div><br></div><div><blockquote style="border: 1px solid rgb(204, 204, 204); padding: 7px; background-color: rgb(245, 245, 245);"><div>(((XMLDOMParser onURL: '<a target="_blank" href="https://w1.weather.gov/xml/current_obs/index.xml">https://w1.weather.gov/xml/current_obs/index.xml</a>' upToLimit:nil)<br></div><div>preservesCDataNodes: true;<br></div><div>preservesCommentNodes: true) parseDocument) explore.<br></div></blockquote><br></div><div><br></div><div>CData and processing-instructions are being preserved, but comments are not.<br></div><div><br></div><div>example slice of the data I add is where you can see the <!--comment--> stuff:<br></div><div><br></div><div><br></div><div><blockquote style="border: 1px solid rgb(204, 204, 204); padding: 7px; background-color: rgb(245, 245, 245);"><div> <s:station subs="yes"><br></div><div> <?s:station-processing-instruction type = "XYZ"?><br></div><div> <!--comment station XYZ--><br></div><div> <![CDATA[<br></div><div> station XYZ CDATA<br></div><div> ]]><br></div><div> <s:station_id>XYZ</s:station_id><br></div><div> <s:state>NZ</s:state><br></div><div> <s:station_name>XYZ_ONE</s:station_name><br></div><div> <s:latitude>51.76667</s:latitude><br></div><div> <s:longitude>-114.68333</s:longitude><br></div><div> <s:html_url><a target="_blank" href="http://w1.weather.gov/data/obhistory/CWAV.html">http://w1.weather.gov/data/obhistory/CWAV.html</a></s:html_url><br></div><div> <s:rss_url><a target="_blank" href="http://weather.gov/xml/current_obs/CWAV.rss">http://weather.gov/xml/current_obs/CWAV.rss</a></s:rss_url><br></div><div> <s:xml_url><a target="_blank" href="http://weather.gov/xml/current_obs/CWAV.xml">http://weather.gov/xml/current_obs/CWAV.xml</a></s:xml_url><br></div><div> <s:substations><br></div><div> <s:substation location="north"><br></div><div> <!--comment station XYZ1--><br></div><div> <s:station_id>XYZ1</s:station_id><br></div><div> <s:state>NZ</s:state><br></div><div> <s:station_name>XYZ_SUB_ONE</s:station_name><br></div><div> </s:substation><br></div><div> <s:substation location="northeast"><br></div><div> <s:station_id>XYZ2</s:station_id><br></div><div> <s:state>NZ</s:state><br></div><div> <s:station_name>XYZ_SUB_TWO</s:station_name><br></div><div> <!--comment station XYZ2--><br></div><div> </s:substation><br></div><div> <s:substation location="east"><br></div><div> <s:station_id>XYZ3</s:station_id><br></div><div> <s:state>NZ</s:state><br></div><div> <s:station_name>XYZ_SUB_THREE</s:station_name><br></div><div> <!--comment station XYZ3--><br></div><div> </s:substation><br></div><div> <s:substation location="south"><br></div><div> <s:station_id>XYZ4</s:station_id><br></div><div> <s:state>NZ</s:state><br></div><div> <s:station_name>XYZ_SUB_FOUR</s:station_name><br></div><div> <!--comment station XYZ4--><br></div><div> </s:substation><br></div><div> <s:substation location="west"><br></div><div> <s:station_id>XYZ5</s:station_id><br></div><div> <s:state>NZ</s:state><br></div><div> <s:station_name>XYZ_SUB_FIVE</s:station_name><br></div><div> <!--comment station XYZ5--><br></div><div> </s:substation><br></div><div> </s:substations><br></div><div> </s:station><br>The intent is to provide practice and examples on more complex axis:node-test[parameter]* paths in the Help/Documentation I am writing.</div></blockquote><br><br>Of these three XPath...only the comment does not work:<br><blockquote style="border: 1px solid rgb(204, 204, 204); padding: 7px; background-color: rgb(245, 245, 245);"><div> self xpath:'/child::node()/child::s:wx_station_index/child::s:station[position()=1]/child::processing-instruction()'. a XPathNodeSet(<?s:station-processing-instruction type = "ABC"?>)<br></div><div> self xpath:'/child::node()/child::s:wx_station_index/child::s:station[position()=1]/child::comment()'. a XPathNodeSet()<br></div><div> self xpath:'/child::node()/child::s:wx_station_index/child::s:station[position()=1]/child::text()'. a XPathNodeSet(<br></div><div> <br></div><div> <br></div><div> <br></div><div> station ABC CDATA<br></div><div> <br></div><div> <br></div><div> <br></div><div> <br></div><div> <br></div><div> <br></div><div> <br></div><div> <br></div><div> <br></div><div> <br></div><div> )<br></div><div> <br></div></blockquote><br><br></div><div><br></div><div>again, just an FYI.<br></div><div><br></div><div>thanks for your time.<br></div><div><br></div><div><br></div><div><br></div><div><br></div><div><br></div><div><br></div></div><br></body></html>