Entities in XML examples

  • Unknown's avatar

    Hi,

    I want to make a point about XML in my blog. I have a line in which I would like to SHOW an entity in code: ? :

    <p>What are you looking at?</p>

    However, The &#x3F keeps showing up as the question mark it stands for. So I tried escaping the ampersand:

    <p>What are you looking at?</p>

    However this does not help, somehow WordPress does a double convert and keeps showing this as the question mark (first converting the & to a & and then the resulting ? in a ?).

    How can I accomplish what I want: Have a ? show up as ? ?????

    Erik Siegel

    PS: I do not want to use the [sourcecode] trick because I don’t like its styling.
    But somehow WordPress keeps giving

    The blog I need help with is: (visible only to logged in users)

  • Unknown's avatar

    All right, even in the blog postings this is formatted wrong… So I cannot even make my point. Grrr.

  • Unknown's avatar

    Try again without the semicolons at the end of the entities to prevend WOrdpress converting them:

    I want to make a point about XML in my blog. I have a line in which I would like to SHOW an entity in code: ? :

    What are you looking at&#x3F

    However, The &#x3F keeps showing up as the question mark it stands for. So I tried escaping the ampersand:

    <p>What are you looking at&amp#x3F</p>

    However this does not help, somehow WordPress does a double convert and keeps showing this as the question mark (first converting the &amp to a & and then the resulting &#x3F in a ?).

    How can I accomplish what I want: Have a &#x#F (plus semicolon) show up as &#x3F ?????

    Erik Siegel

    PS: I do not want to use the [sourcecode] trick because I don’t like its styling.

  • The topic ‘Entities in XML examples’ is closed to new replies.