Wrox Programmer Forums
Go Back   Wrox Programmer Forums > XML > XSLT
|
XSLT General questions and answers about XSLT. For issues strictly specific to the book XSLT 1.1 Programmers Reference, please post to that forum instead.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the XSLT section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old July 21st, 2009, 09:33 AM
Registered User
 
Join Date: Jul 2009
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Conactenation with special charecters

Hi ,

I have to fetch a string which is concatenated with '<' this charecter. When I use concat fucntion it is throwing an exception.

concat('<',"api"). I also tried with &lt; even that is not working. Can somebody suggest a way to concatenate these two ?

Thanks,
Srini
 
Old July 21st, 2009, 09:36 AM
samjudson's Avatar
Friend of Wrox
 
Join Date: Aug 2007
Posts: 2,128
Thanks: 1
Thanked 189 Times in 188 Posts
Default

It is always helpful if you tell us the exception you are receiving when you get one, then we can at least know what exact error you are getting.

You probably need to encode the character, either as &lt; or possible double encoded as &amp;lt; I can't remember.

However if you are trying to output tags as literal text you might be approaching things in the wrong manner, so a little background might provide a much better solution to your problem.
__________________
/- Sam Judson : Wrox Technical Editor -/

Think before you post: What have you tried?
 
Old July 21st, 2009, 09:37 AM
Friend of Wrox
 
Join Date: Nov 2007
Posts: 1,243
Thanks: 0
Thanked 245 Times in 244 Posts
Default

Escaping the less-than sign '<' as '&lt;' should work. If it does not then you need to tell us more details as to what exactly you have tried, show us minimal but complete XML input documents and stylesheet documents and tell us which XSLT processor you use and which exception exactly you get.
__________________
Martin Honnen
Microsoft MVP (XML, Data Platform Development) 2005/04 - 2013/03
My blog
 
Old July 21st, 2009, 12:46 PM
Registered User
 
Join Date: Jul 2009
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi All,

Thanks for your quick response.

I am using IBM tool Datapower and they are using custom parser I believe. However I have got an alternate way and it worked.

Thanks for your help.

Srini





Similar Threads
Thread Thread Starter Forum Replies Last Post
handling xslt ampersand (&) and other charecters like < , > etc vreddy XSLT 9 May 7th, 2009 10:57 AM
> 4000 Charecters mamasagarika Oracle ASP 1 August 5th, 2005 04:12 AM
storing special special characters in nvarchar... ACE2084 SQL Server 2000 2 February 9th, 2005 11:45 AM
Special Character mg1966 Classic ASP Databases 2 December 13th, 2004 11:12 AM
special characters lian_a Classic ASP Basics 3 June 23rd, 2004 05:16 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.