Embedded XML in comments

darren's Avatar

darren

26 Nov, 2008 02:48 AM

My application uses XML to store user data. In a bug reporting a corrupted file I tried to paste the XML, but it only rendered partially. Surrounding it in

 tags did... weird things.  I've included it below (assuming you can see the actual text, and not just the rendered version which I presume will be broken here as well.


<?xml version="1.0" encoding="iso-8859-1"?> Launchpad prototype 2 <start_date>2008-11-25 16:26:35</start_date> <due_date>2008-12-01 23:59:59</due_date> <project_ref id="9b870e95-09e8-4d38-b736-d36b95465ed5"></project_ref>
  1. 1 Posted by darren on 26 Nov, 2008 03:20 AM

    darren's Avatar

    So there appear to be several solutions to this, none of which quite right.

    backticks remove all the newlines in my xml... not quite right

    four spaces work... but they are a major pain for more than say 3 lines of text
    

    @@@ I saw these later, but haven't tried them yet. What would be the proper way to handle this type of preformatted text?

  2. 2 Posted by Rick on 26 Nov, 2008 03:37 AM

    Rick's Avatar

    Use the @@@ tag. You can get simple syntax highlighting with @@@ html

    <start_date>2008-11-25 16:26:35</start_date>
    <due_date>2008-12-01 23:59:59</due_date>
    

    I don't think syntax highlighting in Tender is quite hooked up, but this should work in Lighthouse.

  3. 3 Posted by darren on 26 Nov, 2008 04:49 AM

    darren's Avatar

    Thanks

    @@@ html
    @@@
    

    is the key, much appreciated.

  4. brandi closed this discussion on 29 Jun, 2012 10:05 PM.

Discussions are closed to public comments.
If you need help with Lighthouse please start a new discussion.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac