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

Re: Simple XSLT Problem

simple xslt

Hi Mike,

Instead of
<text>Hello World!</text>

<xsl:text>Hello World!</xsl:text>

I hope this helps!

                      Mike Beattie                                                                                               
                      <mike.beattie@gma        To:       xml-dev@l...                                                   
                      il.com>                  cc:                                                                               
                                               Subject:   Simple XSLT Problem                                           
                      2005-07-14 09:03                                                                                           
                      Please respond to                                                                                          
                      Mike Beattie                                                                                               

I just tried my hand at using XSLT to extract some information from an
XML file that I have been given, and I am running into a (potentially
stupid) problem. I continue to simplify my XSLT query hoping to get to
a point where I see some expected output, and I am still having
difficulties with the files listed below. I am using the latest stable
version of Xalan (1.9.0) on a Linux box.

The problem is that when I apply Xalan to the files below, I get N
blank lines of output, where N is the number of lines in the original
XML file. I would be less confused if N was the number of presentation
elements in my file...but that's not even the case.

I've been banging my head against this one for a little while, and I'm
sure there are people on this list who have a quick answer. Thanks in
advance for any assistance.

--Mike Beattie

........... XSLT File .................................
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"

  <xsl:output method="text"/>

  <xsl:template match="presentation">
    <text>Hello World!&#10;</text>


........... XML File ..................................
<?xml version="1.0" encoding="UTF-8"?>
    name="FRGC - All Signatures - Atomic and Derived"

 <biometric-signature name="nd1S02463">
  <presentation name="nd1R16540" modality="face"
file-name="nd1/Spring2003/02463d258.jpg" file-format="jpeg"/>
 <biometric-signature name="nd1S02463">
  <presentation name="nd1R17900" modality="face"
file-name="nd1/Spring2003/02463d265.jpg" file-format="jpeg"/>

Michael Beattie; Graduate Student
Electrical and Computer Engineering
Carnegie Mellon University

The xml-dev list is sponsored by XML.org <http://www.xml.org>, an
initiative of OASIS <http://www.oasis-open.org>

The list archives are at http://lists.xml.org/archives/xml-dev/

To subscribe or unsubscribe from this list use the subscription
manager: <http://www.oasis-open.org/mlmanage/index.php>


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.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.

Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

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.