Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I extract metadata from the GDB_UserMetadata SDE table. Now I want to transform that xml to html so that I can view it from my browser. To do that I use the ISO.xsl stylesheet found in C:\Program Files\ArcGIS\Metadata\Stylesheets. I add to the beginning of the file:

<?xml-stylesheet type='text/xsl' href='ISO.xsl'?>

It works fine in IE9 but Firefox says:

Error loading stylesheet: Parsing an XSLT stylesheet failed.

Does anyone know WHY?

share|improve this question
    
Use <xsl:stylesheet ...> instead of <xsl-stylesheet....> –  Mapperz Mar 30 '11 at 14:27
    
haven't had this problem. But my first steps would be to clear data in Firefox and specify an absolute path for the stylesheet. What version of firefox are you using? –  badkins Mar 30 '11 at 14:29
    
Thanks for your answers, if I use "xsl:stylesheet" Firefox complains about a not well-formed issue. If I write the absolute path for the .xsl I get a plain text file. IE9 seems to work with anything though. I am using the FF4 but it I had the same problem with the previous version. –  Manolo Frias Mar 31 '11 at 12:16
    
Are both your XML and XSLT valid? Try running through w3.org/2005/08/online_xslt –  Sean Mar 31 '11 at 13:13
    
That validator didn't work for my files but it doesn't seem to work with small xml/xsl files I know are valid. I assumed that ISO.xsl is valid since I took it from the ArcGIS folder in drive C:. If ArcCatalog can transform a xml file I supposed I could do the same from a browser. –  Manolo Frias Apr 1 '11 at 6:56
add comment

2 Answers 2

In short: My answer is just transfrom on server. I has similar expierence as you 2 years ago.

Long story (with ...):

The name "iso.xsl" just suggest "there must be a standard xsl". Because (IMHO) "iso" and "standard" lay nearby in brain of most most of us.

But open that xsl (these xsls, there are about 6 or 9) and read authors.

After a while you'll get the point - esri ...

I'll stop here for a reason I learned yesterday.

There is other side of the story: Firefox was very late with xsl. Not so late as Chrome, but very late...

share|improve this answer
add comment

I believe the tool you want is the XSLTransform_conversion tool. This tool is found in ArcToolbox's Coversion tools. Look in Conversion Tools, then open the Metadata toolset. It's called XSLT Transformation. If you execute it in python, it's the arcpy.XSLTransform_conversion() method. You can look it up in ArcGIS Desktop help for a full description. Here's the link to the online help:

http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//001200000017000000

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.