How to convert tab characters in XSLT

Discussion in 'XML' started by Murtaza Tinwala, Aug 18, 2004.

  1. Hello mates,

    I have to convert an XML document into HTML output through the
    use of XSLT. I am receiving some text content which contains tab
    characters. I have to display this content into TD. How should I
    create HTML tab? I can identify tabs in XSLT. But, how to display
    tabs exactly in HTML? Can anybody help?

    Murtaza.
     
    Murtaza Tinwala, Aug 18, 2004
    #1
    1. Advertising

  2. Murtaza Tinwala wrote:


    > I have to convert an XML document into HTML output through the
    > use of XSLT. I am receiving some text content which contains tab
    > characters. I have to display this content into TD. How should I
    > create HTML tab? I can identify tabs in XSLT. But, how to display
    > tabs exactly in HTML? Can anybody help?


    Whitespace in HTML is usually collapsed, what you can do is use the HTML
    <pre> element to have whitespace rendered e.g.
    <td>
    <pre>
    <xsl:value-of select="yourElement" />
    </pre>
    </td>


    --

    Martin Honnen
    http://JavaScript.FAQTs.com/
     
    Martin Honnen, Aug 18, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    2
    Views:
    769
  2. Stefan Mueller
    Replies:
    3
    Views:
    33,050
    Stefan Mueller
    Jul 23, 2006
  3. omegaman
    Replies:
    1
    Views:
    566
    omegaman
    Sep 21, 2004
  4. Laszlo Nagy
    Replies:
    6
    Views:
    623
  5. Terry Reedy
    Replies:
    0
    Views:
    513
    Terry Reedy
    Jul 1, 2008
Loading...

Share This Page