xsl:text not preserving whitespace

When I try to use <xsl:text> to put spaces into the output of a transform, it does'nt work. Leading/trailing spaces gets stripped and a single space by itself gets dropped altogether.
This is using the PL/SQL XSLT on an XMLType in 9.0.2.
If I run the same transform on the same data but using XALAN XSLT it works fine.

Was that supposed to read:
<xsl:text>& amp;#xa0;</xsl:text>?
(I added whitespace so you could see the ampersand, but that's not a non-breaking space, that's an actual printable character.
I later found a solution that worked in this thread:
Cannot get to print NEWLINE in XMLTransform using XSLT
Posted: May 2, 2007 10:16 AM
Cannot get to print NEWLINE in XMLTransform using XSLT
Thanks,
Eric

Similar Messages

  • Oracle XSLT Transformation not preserving space in text element

    If we have a BPEL process which is calling a XSLT transformation contains the code similar as below:
    for Populating an element with white space only
    <tns:TargetField>
    <xsl:text disable-output-escaping="yes"> </xsl:text> <!--Note the whitespace , also tried with disable-output-escaping =”no” -->
    </tns: TargetField>
    Our expected result / output would be:
    <tns:TargetField> </tns: TargetField> <!--Note the whitespace -->
    But, we get:
    <tns:TargetField/>
    Oracle XSLT is ignoring the white space even if we try with preserve space in XSD, or in XSLT this is not producing the expected output.
    This looks a BUG with Oracle XSLT Transformation .
    For a workaround solution we can use below XSLT snippet:
    *<tns:TargetField>*
    *<xsl:value-of select="string(' ')"/> <!--Note the whitespace -->*
    *</tns:TargetField>*
    This is returning Output:
    *<tns:TargetField> </tns:TargetField> <!--Note the whitespace -->*
    Any other work around do you find?
    Edited by: panks on Jul 29, 2011 12:37 PM

    The workaround only works with one white space, if one put more white spaces, it do not work.
    <tns:TargetField>
    <xsl:value-of select="string(' ')"/> <!--Note the whitespaces -->
    </tns:TargetField>
    This is returning Output:
    <tns:TargetField> </tns:TargetField> <!--Note the only one whitespace -->
    Edited by: user10697506 on Aug 10, 2011 3:27 PM

  • XSL-TEXT: how to import subtemplates in XSL and use xdofx tags?

    Hi,
    I am working on a BI Publisher Report (XML Publisher 5.6.3 in EBS) to generate labels on a label printer. The output needs to be in plain text format, therefore I decided to use the XSL-TEXT template and create my own XSL translation.
    In principle this works pretty fine, but there are two things that worry me a bit:
    1. Does anybody know how I could import other XSL files, like sub-templates in RTF? The problem I have is that I don't know the URI or the sub-template. At the moment I store those other XSL files in the OA_MEDIA folder, but this is not really nice. In RFT you can refer to subtemplates with some xdofx commands... this brings me to my second question:
    2. In RTF templates you can use the Oracle specific XML tags, including the <xdofx:%> and <xdoxslt:%> tags. Does anybody know if and how I can use them in XSL templates?
    Any ideas are highly appreciated!
    regards,
    David.

    Hi Vetsrini,
    1. but what is the absolute path for my subtemplates if I store them in the Template Manager? How can I refer to them?
    This is what the manual says for RTFs:
    >
    Enter the Import Syntax in the Primary Template
    Import the subtemplate to the primary template by entering the following syntax in the
    primary template. The import syntax tells the XML Publisher engine where to find the
    subtemplate RTF in the Template Manager. This syntax may be entered anywhere in the
    template prior to the call-template syntax:
    <?import:xdo://APPCODE.TEMPLATE_CODE.lang.TERR?>
    where
    APPCODE is the Application code you assigned to the subtemplate in the Template
    Manager. For example, if you associated this template with the Receivables application,
    enter "AR".
    TEMPLATE_CODE is the template Code you assigned to the subtemplate in the Template
    Manager. For example, AR_CommonComponents.
    >
    sounds good and easy to me. But I don't have a RTF template. I have just a plain XSLT and those XML Publisher tags do not work there. So how do I get the absolute path of my XSLT templates stored in the Template Manager?
    2. I've included the namespace, no error anymore. But the syntax does not result in actions:
    <xsl:value-of select="xdoxslt:substr((PRODUCT_NAME),1,2)"/>
    {code}
    This does not substring() my string, the full string is returned. But anyway, I don't get an error message anymore. Maybe I just used the wrong XDOXSLT function... I need to search for a list of XDOXSLT functions, but that's not very urgent for now. I think I can do the most with plain XSL and inside the DB itself.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • HTML text not showing properly in CR 11

    I am trying to display the html text in the crystal report but the first screen shot displays something ugly text interpretation:
    But when i change the text interpretation to HTML then instead of showing nice html tags like ul, li AND table tags it is not recognizing the html tags at all
    is there any way to display the html nicely???????

    Not all HTML tags are supported by CR.
    Per KB 1657131, the supported HTML tags in CR2008 and later are:
    html
    body
    div (causes a paragraph break)
    tr (causes only a paragraph break; does not preserve column structure of a table)
    span
    font
    p (causes a paragraph break) 
    br (causes a paragraph break)
    h1 (causes a paragraph break, makes the font bold & twice default size)
    h2 (causes a paragraph break, makes the font bold & 1.5 times default size)
    h3 (causes a paragraph break, makes the font bold & 9/8 default size)
    h4 (causes a paragraph break, makes the font bold)
    h5 (causes a paragraph break, makes the font bold & 5/6 default size)
    h6 (causes a paragraph break, makes the font bold & 5/8 default size)
    center
    big (increases font size by 2 points)
    small (decreases font size by 2 points if it's 8 points or larger)
    b
    i
    s
    strike
    u
    strong
    ol (ordered list)
    ul (unordered list)
    li (list item)
    -Abhilash

  • Is there any way to force Sun C++ Preprocessor preserve whitespace?

    Hello!
    I'm preprocessing simple source file:
    void test()
        int i;
    }with command: CC -E test.cpp
    and CC preprocessor eats all whitespace at the beginning of each line, like this:
    void test()
    int i;
    }Is there any way to force CC preprocessor preserve whitespace?

    You cannot use the C preprocessor on C++ code, for at least two major reasons.
    1. The default -I options in CC are not the same as for cc. Try adding
    #include <iostream>
    #include <cstdlib>
    to your example.
    Even if you add the missing -I options, the conventions for finding the C++ standard headers are not known to the C preprocessor.
    Example:
    % cc -P -I/opt/SUNWspro/prod/include/CC/Cstd -I/opt/SUNWspro/prod/include/CC -I/opt/SUNWspro/prod/include/cc z.c
    "z.c", line 2: cannot find include file: <cstdlib>
    cc: acomp failed for z.c2. The predefined macros (-D options and predefined macros built into the compilers) are different for cc and CC.
    In particular, the C compiler predefines macros saying it is a C compiler. The C++ compiler predefines macros saying it is a C++ compiler. Code that is conditionalized on whether it is compiled by the C or C++ compiler will give different results. If you add -D options for C++ macros, the results will depend on the way the tests are coded. That is, testing for a C compiler or a C++ compiler will not give mutually exclusive answers, as they would if you use the correct compiler. The Solaris headers have conditional code for C and C++.

  • XSL newline not working during runtime

    Hello,
    I have this in my XSL to insert newline during transformation.
    <xsl:variable name="break">
    <xsl:text>
    </xsl:text>
    </xsl:variable>
    It inserts newline when try "Test" from the XSL in JDeveloper.
    However, when I deploy the application to the server and test it, the newline is not coming up in runtime. I am using Oracle JDeveloper 11g(11.1.1.4.0) to create the SOA application and Oracle SOA Suite 11g as my SOA domain server
    Any one came across this, please suggest a solution or workaround.

    Hi,
    To add line breaks, you need to use '&#xA;' in the xsl:value-of. Try the below:
    <xsl:variable name="Test">
    <xsl:value-of select="concat('','&#xA;','')"/>
    </xsl:variable>
    -AR

  • XSL:Text img ... Breaks in transformation

    Hi
    I am sure this is a nobrainer. I am using Java to transform an XML document on the server. What I want to do however is to transform values to a corresponding image on the server. eg Database has value 2 stored. The XSL style sheet then transfroms this to <img src="2">.
    I am using the following
    <td class="tableText"><xsl:text><img src="</xsl:text><xsl:value-of select="PRICE"/><xsl:text>"></xsl:text>I have tried using the disable-output-escaping flag and it doesn't seem to make much difference. If I substitute < for < then this is treated as text by the browser. I am sure I am being stupid so please stop me going mad.

    What you have shown there is not even valid XML, as you are not allowed to have the character < in an attribute. You have to escape it by typing &lt; instead. However, your comments "If I substitute < for < ..." indicate that you probably haven't shown what you actually have, because you don't know how to type the input so that it displays correctly in HTML.
    To get a < character, you must type "&lt;". And if you want to see "&lt;" you must type "&amp;lt;".
    So try again, and show us what you actually have.

  • [svn] 4375: Previous commit did not fix whitespace issue for FxTextArea as advertised.

    Revision: 4375
    Author: [email protected]
    Date: 2008-12-22 09:24:42 -0800 (Mon, 22 Dec 2008)
    Log Message:
    Previous commit did not fix whitespace issue for FxTextArea as advertised. The [CollapseWhiteSpace] metadata has to be on the text getter for FxTextArea. It does not work on the getter for FxTextBase, although it does work for FxTextInput.
    QE Notes:
    Doc Notes: None
    Bugs: SDK-17683
    Ticket Links:
    http://bugs.adobe.com/jira/browse/SDK-17683
    Modified Paths:
    flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/FxTextArea.as

    Revision: 4375
    Author: [email protected]
    Date: 2008-12-22 09:24:42 -0800 (Mon, 22 Dec 2008)
    Log Message:
    Previous commit did not fix whitespace issue for FxTextArea as advertised. The [CollapseWhiteSpace] metadata has to be on the text getter for FxTextArea. It does not work on the getter for FxTextBase, although it does work for FxTextInput.
    QE Notes:
    Doc Notes: None
    Bugs: SDK-17683
    Ticket Links:
    http://bugs.adobe.com/jira/browse/SDK-17683
    Modified Paths:
    flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/FxTextArea.as

  • Font color not preserved in "Duplicate as Master Clip" operation

    When I use Duplicate as Master Clip on a title clip, it does not preserve the font color. It's a pain to have to change the font color every time on what is supposed to be a duplicate.
    Is there a way to copy and keep the same font color?

    Frankly I don't know what you're doing (and I'm not so sure you do either). The only time the Duplicate Master Clip function is available is when an item is selected in the browser. It's not available to a title in the timeline that has been opened from the generators into the viewer. It is only available if the title is in the browser. How and why is this text generator getting into the browser?
    Using the procedure you've described the application behaves correctly. The text if it's made as a duplicate master in the browser is a separate instance, and one dos not effect the other.
    It really doesn't seem as if you're using the application the way it's designed to be used.
    Why is it that when you put a clip into the timeline it has to be rendered? I'm still curious about that.

  • Oracle.xml.parser.v2.XSLException: XSL-1009: Attribute 'xsl:version' not found in 'RO

    I'm using the oracle.xml.parser.v2. The files (xml, xsl) are:
    <?xml version="1.0" ?>
    <?xml-stylesheet type="text/xsl" href="king.xsl" ?>
    <ROWSET>
    <ROW>
    <EMPNO>7839</EMPNO>
    <ENAME>KING</ENAME>
    </ROW>
    </ROWSET>
    <?xml version="1.0"?>
    <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
    <xsl:output method="xml" indent="yes"/>
    <xsl:template match="/">
    <INVITATION>
    <TO>
    <xsl:value-of select="ROWSET/ROW/ENAME"/>
    <xsl:text> &; FAMILY </xsl:text>
    </TO>
    </INVITATION>
    </xsl:template>
    </xsl:stylesheet>
    The error is: oracle.xml.parser.v2.XSLException: XSL-1009: Attribute 'xsl:version' not found in 'ROWSET'.
    The files are well formed (tested with XML Spy 3.5). Can you see what's the problem? or is it a bug with the parser?
    help,
    Alberto
    null

    I encountered the same problem. When I change the order of the XML and XSL files, i am the same problem.
    Perhaps it's the environment AIX 4.3.3, JDK IBM 1.2.2 with JIT disable (because when JIT is enable some other problems become)??
    How can i resolve this bug ?
    Thanks.
    null

  • Plugin settings not preserved from MacPro to G5 - Logic Pro

    Hi there,
    I have an annoying problem - I recently recorded some songs on my Macbook Pro using Logic Pro 7.2.3 and the Renaissance compressor and reverb from the Platinum bundle. I found when I transferred the song files back to my G5 that the Waves plugin settings were not preserved and reverted back to the defaults, and I have had to write down the settings for each track and reset them manually.
    I have the Waves 5.9.1 Platinum bundle on the Macbook Pro and the 5.2.1 bundle on the G5 both running OS X 10.4.9.
    Has you seen this problem before?
    Any comments would be most welcome!
    Regards
    Rick

    Hi there,
    I have done some experimentation on the different platforms, but I still have had no success in resolving this, even though I have installed the latest version of the Waves plugins on my PPC Mac. I do have some comments to make from the tests I made to try to track down the problem.
    Saving the settings in Logic as channel strips or using the down arrow on the Logic frame surrounding the plugin, and selecting 'Save As' do not transfer the settings saved on an Intel based mac to a PPC based one (.aupreset files are saved this way).
    What does work is saving the settings from the 'Save' button on the Waves plugin itself and transferring the .xps file from the Intel Mac to the PPC mac and loading the setting from that file.
    The reason for this may be because the Waves format file (.xps - XML format) stores the plugin settings in human-readable form in the file. The Logic format file (.aupreset - also XML) on the other hand saves the plugin settings as a block of mixed text characters representing the settings as binary data.
    Since this is the case, I think that the PPC Waves plugin can handle its own format files 'cos they are in readable text, but when presented with binary data (which presumably has byte swapped data words in it - Intel and PPC chips differ in this respect) it cannot understand what is being presented to it and fails to load the info.
    If that is the case, Waves need to change their plugins on the PPC platform to understand settings delivered in a binary form from Logic - I keep looking at the Waves site periodically to see if they have.
    Cheers
    Rick
      Mac OS X (10.4.10)  

  • Italics and boldface not preserved in cut-and-paste from InDesign CS3

    This is using Mac InDesign CS3 5.0.1 and Mac Dreamweaver CS3
    9.0.
    When cuting-and-pasting text from InDesign CS3 to Dreamweaver
    CS3, basic text formatting such as italics and boldface are not
    preserved for me. When I select Edit, Paste Special in Dreamweaver,
    the "Text with structure plus basic formatting (bold, italic)" is
    not selectable when the clipboard holds InDesign-origin text.
    If I paste the same InDesign text into Word, the formatting
    is preserved and if I then cut-and-paste from Word into
    Dreamweaver, boldface and italics are preserved. But I don't want
    to cut-and-paste everything twice!
    Do others experience this too?
    -Tim Miller Dyck
    Editor/Publisher
    Canadian Mennonite magazine

    Apparently it is an issue with Leopard (and Illustrator)
    Workarounds:
    1) Export from InDesign as eps or PDF, or
    2) Copy paste into Photoshop as a Smartobject, and then double click the layer to edit smart object (it will open in Illustrator)
    I know, it's a pain.
    Ian

  • Importing clips from iMovie HD does not preserve capture date

    Hi,
    I am importing iMovie HD projects into iMovie 09.
    The clips in iMovie HD (originally imported from DV) have the correct capture date/time on them.
    However, when I import these clips into iMovie 09, it does not preserve these dates for the events but instead chooses to use the "file create date/time" as the event date time.
    Is this info lost forever in iMovie 09 or is there some setting that can use the original clip capture date info as the event date/time?
    Thanks.

    Hi,
    I am importing iMovie HD projects into iMovie 09.
    The clips in iMovie HD (originally imported from DV) have the correct capture date/time on them.
    However, when I import these clips into iMovie 09, it does not preserve these dates for the events but instead chooses to use the "file create date/time" as the event date time.
    Is this info lost forever in iMovie 09 or is there some setting that can use the original clip capture date info as the event date/time?
    Thanks.

  • WAD report export to excel formatting not preserved

    Hi,
    when i export BI 7.1 WAD template to excel and copy to another excel sheet cell formatting changes.color formatting is
    not preserved when we copy to another excel sheet.I tried resetting the "preserve visual appearance of workbook" to the
    exported excel sheet, but this didnot work.I am using excel 2007.
    Can anyone tell me how to preserve the excel formatting for WAD template.
    Thanks,
    Harsha

    Hi Roy
    Have you got the report set to bring back a specific number of rows at a time (ie retrieve data incrementally in sets of : setting in options)?
    If so set this to a larger number of rows, Discoverer will then return all data when the reports is run and will export all data to the spreadsheet.
    Hope this helps
    Melanie

  • SMS texts, not Imessages, on multiple phones with the same Apple ID

    Is it possible that outgoing and incoming SMS texts, not imessages, could be seen on two seperate Iphones that share the same Apple ID? I'm wondering because I have been SMS texting a friend about a gift for my husband and I'm wondering if he was able to read them.
    Thanks!

    Outgoing or Incoming texts? I was texting with a person with an iphone that is one the same network, if that matters.  But they were all green, so i know they were SMS.

Maybe you are looking for

  • Already opened error message while opening GP work item

    Hi Experts We are on NW 7.0 SP 14. We have a custom developed solution integrated with Guided procedure workflow. This workflow was working fine for almost 5-6 months. For last few days we have started getting following issue when one of the step pro

  • CP3525dn, networked -- default duplex for all users (embedded web server)

    I want to set the default for all users on our networked CP3525dn to be duplex. I cannot find this option anywhere in the embedded web server. I have duplex turned on, of course, and users can set their own default to duplex, but I want it to be defa

  • SQL Loader with decimal commas

    Dear All, I am loading data for a German client and the delivered files contain numeric data with decimal commas. For example 123,5 instead of 123.5 I've been googling like mad on this one and there is a lot of chatter about setting NLS_LANG and/or N

  • Leading zeros to alphanumeric string

    Hello all , Does anybody know any function module to put leading zeros to an alphanumeric sequence (18 characters)? Example : 12wer should be '000000000000012wer' CONVERSION_EXIT_ALPHA_INPUT only works with numbers. Thanks in advance , Snehal

  • Essbase BAK, SEC, CFG files

    Gurus, If I want to export-import (copy) Essbase .bak, .sec, and cfg files from one environment how do we copy them. Can I just copy and paste it to the target environment? Also what folder do i need to copy it to? Thanks