[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: Parameter problem

Subject: RE: Parameter problem
From: "David N Bertoni/Cambridge/IBM" <david_n_bertoni@xxxxxxxxxx>
Date: Wed, 13 Mar 2002 15:52:09 -0800
camb parameter
If it has text it has children, since the text content of an element is
represented in the XPath data model as text node children.  Trying to embed
HTML markup as text content is a bad idea, because it will most likely make
your life miserable because it most likely will not work.  There are
numerous threads in the list archives which explain this in great (and
gory) detail.

Embedding markup as text is incompatible with the XSLT processing model and
it's best just not to go there -- just search the archives for
disable-output-escaping and you'll see why.

Dave



|---------+------------------------------------->
|         |           "Hellstern, Manny"        |
|         |           <manny.hellstern@mustangen|
|         |           g.com>                    |
|         |           Sent by:                  |
|         |           owner-xsl-list@xxxxxxxxxxx|
|         |           rrytech.com               |
|         |                                     |
|         |                                     |
|         |           03/13/2002 12:45 PM       |
|         |           Please respond to xsl-list|
|         |                                     |
|---------+------------------------------------->
  >----------------------------------------------------------------------------------------------------------|
  |                                                                                                          |
  |        To:      "'xsl-list@xxxxxxxxxxxxxxxxxxxxxx'" <xsl-list@xxxxxxxxxxxxxxxxxxxxxx>                    |
  |        cc:      (bcc: David N Bertoni/Cambridge/IBM)                                                     |
  |        Subject: RE:  Parameter problem                                                              |
  >----------------------------------------------------------------------------------------------------------|



Maybe my problem lies in the fact that INTROMSG should not have any
children. What I'm trying to do is embed the HTML img tag inline with some
text.

-----Original Message-----
From: Peter Davis [mailto:pdavis152@xxxxxxxxx]
Sent: Wednesday, March 13, 2002 2:27 PM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re:  Parameter problem


On Wednesday 13 March 2002 11:57, Dion Houston wrote:
> Try using <xsl:copy-of select="//INTROMSG/*|//INTROMSG/text()"/>

If you are just trying to copy all of the children of INTROMSG, it would be

simpler to use:

<xsl:copy-of select="//INTROMSG/node()"/>

Using node() matches both "*" and "text()".

Another suggestion: it sounds like there is only one INTROMSG in the
document.  In this case, it would be better to tell the processor to only
match the first one to prevent it from searching the entire document for
all

of them (this can get hefty if it is a large document).  So you should
maybe

try also something like:

<xsl:copy-of select="//INTROMSG[1]/node()"/>

Or,

<xsl:copy-of select="/full/path/to/INTROMSG/node()"/>

--
Peter Davis
Marriage is the process of finding out what kind of man your wife would
have preferred.

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list







 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.