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. how xml embeds (saves) an image

how xml embeds (saves) an image

Scheduled Pinned Locked Moved XML / XSL
xmlquestion
4 Posts 3 Posters 2 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.
  • A Offline
    A Offline
    Asim N
    wrote on last edited by
    #1

    hello i want to know how xml handles image, here is a scenario let say i have a word document(having an image inserted in it) and i want to change this document to xml, now how xml would save or handle this image, the whole image would b embeded or just a path of it or ?:confused: Asim

    B 1 Reply Last reply
    0
    • A Asim N

      hello i want to know how xml handles image, here is a scenario let say i have a word document(having an image inserted in it) and i want to change this document to xml, now how xml would save or handle this image, the whole image would b embeded or just a path of it or ?:confused: Asim

      B Offline
      B Offline
      berndg
      wrote on last edited by
      #2

      Asim, I think you must consider your requirements: is it required a single (Word) document must be represented by a *single* XML document? (in which case the answer is obvious). Otherwise, I suggest referencing. After all, there is only a very small number of graphics formats that lend themselves to XML encoding in an acceptable way. Embedding a JPEG in XML doesn't sound very efficient to me. Bernd

      A 1 Reply Last reply
      0
      • B berndg

        Asim, I think you must consider your requirements: is it required a single (Word) document must be represented by a *single* XML document? (in which case the answer is obvious). Otherwise, I suggest referencing. After all, there is only a very small number of graphics formats that lend themselves to XML encoding in an acceptable way. Embedding a JPEG in XML doesn't sound very efficient to me. Bernd

        A Offline
        A Offline
        Asim N
        wrote on last edited by
        #3

        well, sir. consider a word document in whcih a picture is inserted, now i want to change this document to xml, now what i was saying is that how the target, which is xml file would save this picture, like a href or ref in html or would save the whole picture in the form of pixels or whatever, this is what i want to know. ASIM Asim

        M 1 Reply Last reply
        0
        • A Asim N

          well, sir. consider a word document in whcih a picture is inserted, now i want to change this document to xml, now what i was saying is that how the target, which is xml file would save this picture, like a href or ref in html or would save the whole picture in the form of pixels or whatever, this is what i want to know. ASIM Asim

          M Offline
          M Offline
          Michael A Barnhart
          wrote on last edited by
          #4

          Asim, Next time I would have phrased the question differently. (How does word save an embedded picture in it's xml file.) XML will save the file in what ever manner the app handles (assuming it is a valid file.) So it could save the picture on the side and insert a reference in the appropriate XML element. I would guess that word encodes the file (just like a server does sending it out over the internet) and sets an elements CData section with that encoded text string. If you have word just do a sample doc with a small picture in it. "I will find a new sig someday."

          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