Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

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

Urgent (wd-xsl)

Hello,
i have a stylesheet designed in wd-xsl and i want to dynamically transform my xml file to that stylesheet,but as it is the older stylesheet it is not transformed by these days xsl processor. i too tried to convert xsl to xsl using xsl to xslt converter but that one cannot transform fully to xslt.
from javascript i did the transformation using msxxml dom document3.0 but,it sometime works and sometime it doesnot works.

i also tried to create processing instruction from javascript and jsp at the runtime using dom.now how can i show the xml file in internet explorer with dynamically transformed stylesheet(using created processing instruction)??

and is there any xsl processor rather than msxml3.0 which can process wd-xsl stylesheet??

thanks in advance
0
sansaj
Asked:
sansaj
  • 4
  • 3
1 Solution
 
ramazanyichCommented:
First of all you should replace your stylesheet definition:
<xsl:stylesheet
         language="JavaScript"
       xmlns:xsl="http://www.w3.org/TR/WD-xsl"
       xmlns="http://www.w3.org/TR/REC-html40"
       result-ns="">

by standard
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

Also sometimes it was default rule added to the stylesheet:
<!-- default rule -->
<xsl:template><xsl:apply-templates/></xsl:template>

remove it.

some functions has to be replaced.
Better if you send your old xsl. I will try to convert it.
I don't think that there is a good converters from wd-xsl to standard xsl are exist. because wd-xsl is mostly were implemented by microsoft.

0
 
sansajAuthor Commented:
hey thanks
the old xsl is available at
http://www.esri.com/metadata/fgdc_esri.xsl


thanks
0
 
ramazanyichCommented:
replace all context()[ calls by .[
replace all end() function calls by not(last())
replace all $any$ calls by similiar or constructions.

0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
sansajAuthor Commented:
>>replace all $any$ calls by similiar or constructions.

what does similar or constructions means.???
0
 
ramazanyichCommented:
for example you have following expression: /metadata/idinfo/keywords[$any$ */(themekey | placekey | stratkey | tempkey) != '']

It should be replaced by:
(/metadata/idinfo/keywords[child::*/themekey != ''] or /metadata/idinfo/keywords[child::*/placekey != ''] or /metadata/idinfo/keywords[child::*/stratkey != ''] or /metadata/idinfo/keywords[child::*/tempkey!= ''] )
0
 
ramazanyichCommented:
in my suggestion "replace end() by not(last())" was mistake:
it should be:
replace end() by last()
0
 
sansajAuthor Commented:
Thanks i am trying this one
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

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