I am querying the Microsoft Office SharePoint Server Search Service to write some results into a web part. I have the query working correctly but am having some trouble parsing the xml response via JQuery.
Below is the XML response :
<document>
<properties>
<Property>
<Name>p1</Name>
<Type>String</Type>
<Value>blue</Value>
</Property>
<Property>
<Name>title</Name>
<Type>string</Type>
<Value>titreA</Value>
</Property>
</properties>
</document>
<document>
<properties>
<Property>
<Name>p1</Name>
<Type>String</Type>
<Value>blue</Value>
</Property>
<Property>
<Name>title</Name>
<Type>string</Type>
<Value>titreB</Value>
</Property>
</properties>
</document>
<document>
<properties>
<Property>
<Name>p1</Name>
<Type>String</Type>
<Value>green</Value>
</Property>
<Property>
<Name>title</Name>
<Type>string</Type>
<Value>titreC</Value>
</Property>
</properties>
</document>
<document>
<properties>
<Property>
<Name>p1</Name>
<Type>String</Type>
<Value>red</Value>
</Property>
<Property>
<Name>title</Name>
<Type>string</Type>
<Value>titreD</Value>
</Property>
</properties>
</document>
How can i retrieve p1 value, and number of occurence of this value ? Like this : blue(2), green(1), red(1)