<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic XPath Two Levels of Attributes in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/XPath-Two-Levels-of-Attributes/m-p/78004#M4219</link>
    <description>&lt;P&gt;With this XML:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;serverVariables&amp;gt;
&amp;lt;item name="GATEWAY_INTERFACE"&amp;gt;
   &amp;lt;value string="CGI/1.1" /&amp;gt;
 &amp;lt;/item&amp;gt;
 &amp;lt;item name="HTTPS"&amp;gt;
   &amp;lt;value string="off" /&amp;gt;
 &amp;lt;/item&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;How can I use the XPATH command to get key value pairs like:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;GATEWAY_INTERFACE:CGI/1.1
HTTPS:off
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Fri, 08 Apr 2011 19:36:07 GMT</pubDate>
    <dc:creator>Kyle_Brandt</dc:creator>
    <dc:date>2011-04-08T19:36:07Z</dc:date>
    <item>
      <title>XPath Two Levels of Attributes</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/XPath-Two-Levels-of-Attributes/m-p/78004#M4219</link>
      <description>&lt;P&gt;With this XML:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;serverVariables&amp;gt;
&amp;lt;item name="GATEWAY_INTERFACE"&amp;gt;
   &amp;lt;value string="CGI/1.1" /&amp;gt;
 &amp;lt;/item&amp;gt;
 &amp;lt;item name="HTTPS"&amp;gt;
   &amp;lt;value string="off" /&amp;gt;
 &amp;lt;/item&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;How can I use the XPATH command to get key value pairs like:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;GATEWAY_INTERFACE:CGI/1.1
HTTPS:off
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 08 Apr 2011 19:36:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/XPath-Two-Levels-of-Attributes/m-p/78004#M4219</guid>
      <dc:creator>Kyle_Brandt</dc:creator>
      <dc:date>2011-04-08T19:36:07Z</dc:date>
    </item>
    <item>
      <title>Re: XPath Two Levels of Attributes</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/XPath-Two-Levels-of-Attributes/m-p/78005#M4220</link>
      <description>&lt;P&gt;Figured it out for at least a specific field:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;xpath "//item/[@name='HTTPS']/value/@string" outfield=LOATH_XML
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 08 Apr 2011 20:05:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/XPath-Two-Levels-of-Attributes/m-p/78005#M4220</guid>
      <dc:creator>Kyle_Brandt</dc:creator>
      <dc:date>2011-04-08T20:05:21Z</dc:date>
    </item>
  </channel>
</rss>

