Extract Data from XML file.

Hi Guys,

I am in a need to extract data from a xml file. The XML file format is as below.

<data jsxnamespace="propsbundle" locales="">
  <locale>

        <!--Error messages starts-->
        <record jsxid="CHARPAIR001" jsxtext=" must be selected"></record>
        <record jsxid="CHARPAIR002" jsxtext="Too many records selected - limit to 1 only"></record>
        <record jsxid="CHARPAIR003" jsxtext="User does not have permission to perform the requested action"></record>
        <record jsxid="CHARPAIR004" jsxtext="  Type must be selected"></record>
        <record jsxid="CHARPAIR005" jsxtext="  Type must be selected"></record>
        <record jsxid="CHARPAIR006" jsxtext="   should not be the same - amend selection"></record>
        <record jsxid="CHARPAIR007" jsxtext="Confirm Deletion?"></record>
        <record jsxid="CHARPAIR008" jsxtext="  must be selected"></record>
        <!--CR 343 adderelease 4.5 version Changes starts-->
        <record jsxid="CHARPAIR009" jsxtext="TYPE must be selected"></record>
        <record jsxid="CHARPAIR010" jsxtext=" Value must be filled"></record>
        <record jsxid="CHARPAIR011" jsxtext=" Value must be filled"></record>
        <record jsxid="CHARPAIR012" jsxtext="Existing Value must be selected"></record>
        <!--version Changes ends-->
        <!--Error messages ends-->

  </locale>
</data>

I want the values embeded in double quotes separated by a comma.

perl -ne 'chomp;while(/(\".*?\")/g){print "$1,"}' file.xml