Easy A
Would you like to react to this message? Create an account in a few clicks or log in to continue.


 
HomeHome  Latest imagesLatest images  SearchSearch  RegisterRegister  Log inLog in  

Share
 

 Default namespace and XSLT

View previous topic View next topic Go down 
AuthorMessage
Special Ops
Member
Member
Special Ops

Posts : 3
Join date : 2011-06-21

Default namespace and XSLT Empty
PostSubject: Default namespace and XSLT   Default namespace and XSLT EmptyTue Jun 21, 2011 7:38 pm

Hi,

I got a default namespace as xmlns="path/to/default/namespace/" in my xml file, and following is what I am using for xsl file:
Code:

<xsl:stylesheet version="1.0"
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  xmlns:h="path/to/default/namespace/"
  exclude-result-prefixes="h"
  xmlns="http://www.w3.org/1999/xhtml">

It is not working, just breaks the page. when I remove the attribute xmlns from xml file then it works fine, but with default namespace it doesn't.

Is there anyone tell me how can i get it working with default namespace?

Thanks.
Back to top Go down
mojito
Member
Member
mojito

Posts : 2
Join date : 2011-06-21

Default namespace and XSLT Empty
PostSubject: Re: Default namespace and XSLT   Default namespace and XSLT EmptyTue Jun 21, 2011 7:38 pm

either you access the XML elements with the h: prefix in your XSL or you change the XSL’s default namespace.
Back to top Go down
Special Ops
Member
Member
Special Ops

Posts : 3
Join date : 2011-06-21

Default namespace and XSLT Empty
PostSubject: Re: Default namespace and XSLT   Default namespace and XSLT EmptyTue Jun 21, 2011 7:39 pm

I tried using with h: but didn't work, what should I change to for default namespace?
Back to top Go down
BadAddy
Member
Member
BadAddy

Posts : 6
Join date : 2011-06-05

Default namespace and XSLT Empty
PostSubject: Re: Default namespace and XSLT   Default namespace and XSLT EmptyTue Jun 21, 2011 7:40 pm

Hi,

I also have this problem now, where the Xpath/XSLT navigation doesn't work if there is a default namespace in the XML file.

Any solutions to this?
Back to top Go down
Sponsored content




Default namespace and XSLT Empty
PostSubject: Re: Default namespace and XSLT   Default namespace and XSLT Empty

Back to top Go down
 

Default namespace and XSLT

View previous topic View next topic Back to top 
Page 1 of 1

Permissions in this forum:You cannot reply to topics in this forum
Easy A :: Default namespace and XSLT Edit-trash Useless :: Trash-