Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 164
  • Last Modified:

Adding attribute values to variables

Hello Experts,

I have config xml file which contains below structure. I have add @as_Name values in variable(cfg) so that i can use this variable for further processing in which i would like to do <xsl:if test="$cfg=$pkg"> or <xsl:if test="contains($cfg,$pkg)">.

Also, the variable cfg should contains unique substring-before colon only values.  

can you please suggest the xslt code for achieving this?

Thanks,
Shailesh
config xml file:
 
<jsclasses>
<jslrtoc>
<category name="Functions">
<class as_Name="trace">window.runtime.trace</class>
<class as_Name="flash.net:navigateToURL">window.runtime.flash.net.navigateToURL</class>
<class as_Name="flash.net:sendToURL">window.runtime.flash.net.sendToURL</class>
</category>
<category name="File">
<class as_Name="flash.filesystem:File">window.runtime.flash.filesystem.File</class>
<class as_Name="flash.filesystem:FileStream">window.runtime.flash.filesystem.FileStream</class>
<class as_Name="flash.filesystem:FileMode">window.runtime.flash.filesystem.FileMode</class>
</category>
<category name="Events">
<class as_Name="flash.events:ActivityEvent">window.runtime.flash.events.ActivityEvent</class>
<class as_Name="flash.events:AsyncErrorEvent">window.runtime.flash.events.AsyncErrorEvent</class>
<class as_Name="flash.events:BrowserInvokeEvent">window.runtime.flash.events.BrowserInvokeEvent</class>
<class as_Name="flash.events:DataEvent">window.runtime.flash.events.DataEvent</class>
<class as_Name="flash.events:DRMAuthenticateEvent">window.runtime.flash.events.DRMAuthenticateEvent</class>
<class as_Name="flash.events:DRMStatusEvent">window.runtime.flash.events.DRMStatusEvent</class>
<class as_Name="flash.events:ErrorEvent">window.runtime.flash.events.ErrorEvent</class>
<class as_Name="flash.events:Event">window.runtime.flash.events.Event</class>
<class as_Name="flash.events:EventDispatcher">window.runtime.flash.events.EventDispatcher</class>
<class as_Name="flash.events:FileListEvent">window.runtime.flash.events.FileListEvent</class>
<class as_Name="flash.events:HTTPStatusEvent">window.runtime.flash.events.HTTPStatusEvent</class>
<class as_Name="flash.events:IOErrorEvent">window.runtime.flash.events.IOErrorEvent</class>
<class as_Name="flash.events:InvokeEvent">window.runtime.flash.events.InvokeEvent</class>
<class as_Name="flash.events:NetStatusEvent">window.runtime.flash.events.NetStatusEvent</class>
<class as_Name="flash.events:OutputProgressEvent">window.runtime.flash.events.OutputProgressEvent</class>
<class as_Name="flash.events:ProgressEvent">window.runtime.flash.events.ProgressEvent</class>
<class as_Name="flash.events:SecurityErrorEvent">window.runtime.flash.events.SecurityErrorEvent</class>
<class as_Name="flash.events:StatusEvent">window.runtime.flash.events.StatusEvent</class>
<class as_Name="flash.events:TimerEvent">window.runtime.flash.events.TimerEvent</class>
<class as_Name="flash.events:SampleDataEvent">window.runtime.flash.events.SampleDataEvent</class>
</category>
.....
.....
.....
.....

Open in new window

0
ShaileshShinde
Asked:
ShaileshShinde
1 Solution

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now