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. Attribute value choking parser?

Attribute value choking parser?

Scheduled Pinned Locked Moved XML / XSL
xmlquestionhtmlhelpannouncement
3 Posts 3 Posters 9 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.
  • S Offline
    S Offline
    SigEpUCI
    wrote on last edited by
    #1

    Hi guys, not well versed in XML here.. *** Update -- After reading a document on well formed XML, I realized that ampersands in XML attributes need to appear as & or the numeric code. Please Ignore this post. Thanks! **** When I try to load the following XML string into a XmlDocument object (or IE for that matter) I get the following error: [From IE] The XML page cannot be displayed Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later. -------------------------------------------------------------------------------- A semi colon character was expected. Error processing resource 'file:///C:/VSProjects/WinForumProjects/WinForumInstallDirectory/ServerContentTest.xml'. Line 2, Position 65 The error occures right after the '&forum=' part of the attribute. It would seem to be trying to parse the attribute as HTML or something. How can I get the object to ignore the actual values of the attribute? Thanks Jeff

    M Z 2 Replies Last reply
    0
    • S SigEpUCI

      Hi guys, not well versed in XML here.. *** Update -- After reading a document on well formed XML, I realized that ampersands in XML attributes need to appear as & or the numeric code. Please Ignore this post. Thanks! **** When I try to load the following XML string into a XmlDocument object (or IE for that matter) I get the following error: [From IE] The XML page cannot be displayed Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later. -------------------------------------------------------------------------------- A semi colon character was expected. Error processing resource 'file:///C:/VSProjects/WinForumProjects/WinForumInstallDirectory/ServerContentTest.xml'. Line 2, Position 65 The error occures right after the '&forum=' part of the attribute. It would seem to be trying to parse the attribute as HTML or something. How can I get the object to ignore the actual values of the attribute? Thanks Jeff

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

      Can you modify your post and turn off the html. Can not see the XML. If you insist in finding evil in me you will find it, whether it is there or not.

      1 Reply Last reply
      0
      • S SigEpUCI

        Hi guys, not well versed in XML here.. *** Update -- After reading a document on well formed XML, I realized that ampersands in XML attributes need to appear as & or the numeric code. Please Ignore this post. Thanks! **** When I try to load the following XML string into a XmlDocument object (or IE for that matter) I get the following error: [From IE] The XML page cannot be displayed Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later. -------------------------------------------------------------------------------- A semi colon character was expected. Error processing resource 'file:///C:/VSProjects/WinForumProjects/WinForumInstallDirectory/ServerContentTest.xml'. Line 2, Position 65 The error occures right after the '&forum=' part of the attribute. It would seem to be trying to parse the attribute as HTML or something. How can I get the object to ignore the actual values of the attribute? Thanks Jeff

        Z Offline
        Z Offline
        Zdenek Navratil
        wrote on last edited by
        #3

        You have a single & character in your xml. Character & cannot be used in text as it is used in markup (the same applies to < character). Replace each occurence of a single character '&' by a sequence of 5 chars &_a_m_p_;. I can't write them here together for the browser would render them to a single &. Just get rid of '_' from the presented sequence. HTH, Zdenek "It's never too late to have a happy childhood." [Tom Robbins]

        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