Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. XML / XSL
  4. Xml - Element or CDATA

Xml - Element or CDATA

Scheduled Pinned Locked Moved XML / XSL
questionxml
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Mike HankeyM Offline
    Mike HankeyM Offline
    Mike Hankey
    wrote on last edited by
    #1

    If one of my Xml elements can potentially hold a large amount of data should I be using Element or CDATA. What is the difference between the two? As an aside this is my 100 post...yipee?

    Everybody gotta be somebody

    S 1 Reply Last reply
    0
    • Mike HankeyM Mike Hankey

      If one of my Xml elements can potentially hold a large amount of data should I be using Element or CDATA. What is the difference between the two? As an aside this is my 100 post...yipee?

      Everybody gotta be somebody

      S Offline
      S Offline
      Stefan Troschuetz
      wrote on last edited by
      #2

      Mike Hankey wrote:

      should I be using Element or CDATA

      Since a CDATA section is nested inside an element the question should be: Should I use a CDATA section or not.

      Mike Hankey wrote:

      What is the difference between the two?

      A CDATA section is ignored by the parser but also applies some requirements on the data it holds. Take a look at this link XML CDATA[^].

      Mike Hankey wrote:

      As an aside this is my 100 post

      Congratulation :)


      "Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook

      www.troschuetz.de

      Mike HankeyM 1 Reply Last reply
      0
      • S Stefan Troschuetz

        Mike Hankey wrote:

        should I be using Element or CDATA

        Since a CDATA section is nested inside an element the question should be: Should I use a CDATA section or not.

        Mike Hankey wrote:

        What is the difference between the two?

        A CDATA section is ignored by the parser but also applies some requirements on the data it holds. Take a look at this link XML CDATA[^].

        Mike Hankey wrote:

        As an aside this is my 100 post

        Congratulation :)


        "Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook

        www.troschuetz.de

        Mike HankeyM Offline
        Mike HankeyM Offline
        Mike Hankey
        wrote on last edited by
        #3

        Stefan, Thanks for the information. CData it is, because the information may contain <> and other chars that may offend the parser.

        Stefan Troschuetz wrote:

        Mike Hankey wrote: As an aside this is my 100 post Congratulation

        I don't feel any different am I supposed to???:):)

        Everybody gotta be somebody

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups