Results 1 to 5 of 5

Thread: [Solved]Printing XML

  1. #1
    Ext User
    Join Date
    Dec 2008
    Posts
    14
    Vote Rating
    0
      0  

    Question [Solved]Printing XML

    Hi!

    I'm trying to print a XML object into a Panel. My objects comes into a JSON object from server.
    The data is printed into the panel, but all tags are missed. I only can see them if I look at source code of the page.
    Is there any way to format my XML? I couldn't find it anywhere.

    thanks in advance
    R.H.

  2. #2
    Sencha - Community Support Team Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,246
    Vote Rating
    118
      0  

    Default

    Use Ext.util.Format.htmlEncode.

  3. #3
    Ext User
    Join Date
    Dec 2008
    Posts
    14
    Vote Rating
    0
      0  

    Default

    OK!
    It works. And last question, is it possible to 'format' the XML to show it like "pretty print"? or I'll have to proccess it?

    thanks a lot

  4. #4
    Sencha - Community Support Team Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,246
    Vote Rating
    118
      0  

    Default

    You'll have to do the formatting yourself.

    ps. You're not actually showing XML, you are showing a string.

  5. #5
    Ext User
    Join Date
    Dec 2008
    Posts
    14
    Vote Rating
    0
      0  

    Default

    ok. thanks!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •