Hi ,
could any one post the answer with in one day or as soon as possible is a grate help for me..Thanks in advance
iam new to xsl..
i want to convert the plist using xsl to xml file as output.
i need xsl code for the given below plist to produce output as xml.
The Apple plist file format is a very special kind of xml, so I plan to convert it to a more standard XML file.
Plist code :
In this Plist,the xml output should work for boolean values and array values with seperator comma, .
For example :
Plist :
<key>booleanAnswer</key>
<false/>
<key>imageNameList</key>
<array>
<string>haiiimage</string>
<string>hellostringimage</string>
</array>
xsl :
xsl should parse plist in such a way that it works for boolean and array in a proper xml formatxml:
<booleanAnswer>false </booleanAnswer>
<imageNameList > haiimage , hellosringimage </imageNameLis>
Code:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>surveyUniqueIndentifier</key>
<string></string>
<key>storeId</key>
<string></string>
<key>answersList</key>
<array>
<dict>
<key>questionId</key>
<string>qid001</string>
<key>categoryId</key>
<string>cid001</string>
<key>comments</key>
<string>hai</string>
<key>booleanAnswer</key>
<false/>
<key>imageNameList</key>
<array>
<string>helloimage</string>
<string>haiimage</string>
</array>
<key>selectionList</key>
<array>
<string>1</string>
<string>2</string>
</array>
</dict>
<dict>
<key>questionId</key>
<string>qid002</string>
<key>categoryId</key>
<string>catid002</string>
<key>comments</key>
<string>hellocomments</string>
<key>booleanAnswer</key>
<false/>
<key>imageNameList</key>
<array>
<string>haiiimage</string>
<string>hellostringimage</string>
</array>
<key>selectionList</key>
<array>
<string>a</string>
<string>b</string>
</array>
</dict>
<dict>
<key>questionId</key>
<string>qid003</string>
<key>categoryId</key>
<string>catid003</string>
<key>comments</key>
<string>commwnt3</string>
<key>booleanAnswer</key>
<false/>
<key>imageNameList</key>
<array>
<string>image1</string>
<string>image2</string>
</array>
<key>selectionList</key>
<array>
<string>abc</string>
<string>xyz</string>
</array>
</dict>
</array>
</dict>
</plist>
Xsl I got from google ..but it should work for arrays and booleans.