Bizarre display behavior with "+" and "-" signs in IE 6.0 only

Discussion in 'HTML' started by Jay, Jan 7, 2004.

  1. Jay

    Jay Guest

    Hi,

    I'm getting very strange behavior when trying to display HTML that contains
    plus and minus signs in a certain sequence. The issue has to do with a plus
    sign followed by alphanumeric characters followed by a minus sign (with no
    spaces in-between). It's easier to show than explain. Could someone try
    copying the following 3 samples and tell me what IE displays for you in each
    case? I'm using IE 6.0 SP1.

    (1)
    <html>
    <body>
    +8-
    </body>
    </html>
    (displays nothing)

    (2)
    <html>
    <body>
    a+a-t
    </body>
    </html>
    (displays "at")

    (3)
    <html>
    <body>
    8+947asdf7987fdsfd-9
    </body>
    </html>
    (displays "8??????9")

    Note that the alphanumeric characters used in each sample are random; if I
    use other characters, I still get the strange behavior. I've rebooted and
    also tried on another machine (also running IE 6.0 SP1).

    Can anyone shed light on this perplexing behavior?

    Thanks,
    Jay
    Jay, Jan 7, 2004
    #1
    1. Advertising

  2. Jay

    Jay Guest

    > (displays "8??????9")

    Hopefully, this'll display correctly if I post in HTML format. Your newsreader may display it, but the question marks should be boxes:
    (displays "8ïžŽíª±íŸ»ïŸŽí½¶ìŸ9")
    Jay, Jan 7, 2004
    #2
    1. Advertising

  3. Jay

    John McGaw Guest

    "Jay" <> wrote in message
    news:3ffb5b16$0$32589$...
    > Hi,
    >
    > I'm getting very strange behavior when trying to display HTML that

    contains
    > plus and minus signs in a certain sequence. The issue has to do with a

    plus
    > sign followed by alphanumeric characters followed by a minus sign (with no
    > spaces in-between). It's easier to show than explain. Could someone try
    > copying the following 3 samples and tell me what IE displays for you in

    each
    > case? I'm using IE 6.0 SP1.
    >
    > (1)
    > <html>
    > <body>
    > +8-
    > </body>
    > </html>
    > (displays nothing)
    >
    > (2)
    > <html>
    > <body>
    > a+a-t
    > </body>
    > </html>
    > (displays "at")
    >
    > (3)
    > <html>
    > <body>
    > 8+947asdf7987fdsfd-9
    > </body>
    > </html>
    > (displays "8??????9")
    >
    > Note that the alphanumeric characters used in each sample are random; if I
    > use other characters, I still get the strange behavior. I've rebooted and
    > also tried on another machine (also running IE 6.0 SP1).
    >
    > Can anyone shed light on this perplexing behavior?
    >
    > Thanks,
    > Jay
    >


    It has something to do with the browser's automatic selection of encoding.
    Try right-clicking on the displayed errors and select one of the appropriate
    encoding options and watch what happens. Turn off automatic selection and it
    is changes too. Don't really have a clue as to why it is acting this way
    unless the characters you chose are considered special by the selection
    process but that seems to be too dumb to be believed, even for MS.
    --
    John McGaw
    [Knoxville, TN, USA]

    Return address will not work. Please
    reply in group or through my website:
    http://johnmcgaw.com
    John McGaw, Jan 7, 2004
    #3
  4. Jay

    Jay Guest

    "John McGaw" <> wrote in message
    news:15JKb.259$...
    >
    > It has something to do with the browser's automatic selection of encoding.
    > Try right-clicking on the displayed errors and select one of the

    appropriate
    > encoding options and watch what happens. Turn off automatic selection and

    it
    > is changes too. Don't really have a clue as to why it is acting this way
    > unless the characters you chose are considered special by the selection
    > process but that seems to be too dumb to be believed, even for MS.


    Thanks for demystifying this, John. What's odd is that it displays correctly
    with every other endoding option *except* the default (UTF-7). What's even
    more bizarre is that I started off troubleshooting the JavaScript for the
    page in question because I was getting various JavaScript errors. When I
    realized there was absolutely nothing wrong with the JavaScript, I
    eventually whittled down a rather large page to that one character
    combination. So in addition to the problem of the characters just not
    showing up, they were causing JS errors. Something clearly ain't workin'
    right!

    Thanks for your help John,
    Jay
    Jay, Jan 7, 2004
    #4
  5. Jay

    Mark Parnell Guest

    On Tue, 6 Jan 2004 21:29:31 -0800, Jay declared in alt.html:
    >
    > Thanks for demystifying this, John. What's odd is that it displays correctly
    > with every other endoding option *except* the default (UTF-7).


    Why are you using UTF-7 on a web page?

    From http://www.faqs.org/rfcs/rfc2152.html :

    Also as a special case, the sequence "+-" may be used to encode the
    character "+". A "+" character followed immediately by any character
    other than members of set B or "-" is an ill-formed sequence.

    --
    Mark Parnell
    http://www.clarkecomputers.com.au
    Mark Parnell, Jan 7, 2004
    #5
  6. Jay

    Jay Guest

    "Mark Parnell" <> wrote in message
    news:65vmxlv0y8tr$.xg7ey4mf6x8y$...
    >
    > Why are you using UTF-7 on a web page?


    I'm not. As I said, it was the default setting. I don't know how it got that
    way cuz I sure didn't change it; I never modify the encoding option when
    browsing, so maybe I had browsed to a page set to UTF-7 immediately before
    encountering this issue.

    > From http://www.faqs.org/rfcs/rfc2152.html :
    >
    > Also as a special case, the sequence "+-" may be used to encode the
    > character "+". A "+" character followed immediately by any character
    > other than members of set B or "-" is an ill-formed sequence.


    Thanks for the info.

    Jay
    Jay, Jan 7, 2004
    #6
  7. Jay

    rf Guest

    "Jay" <> wrote in message
    news:3ffb5ca0$0$32586$...
    > (displays "8??????9")


    Hopefully, this'll display correctly if I post in HTML format. Your
    newsreader may display it, but the question marks should be boxes:
    (displays "8??????9")

    PLEASE do not post in HTML!
    rf, Jan 7, 2004
    #7
  8. "Jay" <> wrote:

    >> Why are you using UTF-7 on a web page?

    >
    > I'm not. As I said, it was the default setting. I don't know how it
    > got that way cuz I sure didn't change it; I never modify the
    > encoding option when browsing, so maybe I had browsed to a page set
    > to UTF-7 immediately before encountering this issue.


    Quite probably so. But then the problem was, in part, caused by the
    test page you viewed - or, rather, by the lack of charset specification
    in its HTTP headers, or even a simulation thereof in a <meta> tag.

    When you view a page that has no encoding information, browsers tend to
    imply the last encoding used, carrying it over from the previous page.
    This may cause great confusion.

    --
    Yucca, http://www.cs.tut.fi/~jkorpela/
    Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html
    Jukka K. Korpela, Jan 7, 2004
    #8
  9. Jay

    Jay Guest

    "Jukka K. Korpela" <> wrote in message
    news:Xns9469933857A02jkorpelacstutfi@193.229.0.31...
    >
    > Quite probably so. But then the problem was, in part, caused by the
    > test page you viewed - or, rather, by the lack of charset specification
    > in its HTTP headers, or even a simulation thereof in a <meta> tag.


    Yes. This was a test page whose meta tags hadn't yet been set. Because I was
    getting JavaScript errors, naturally the JS code was the first place I
    looked, and I was getting JS errors as long as the +...- character combo was
    on the page (not sure why it affected the totally unrelated JS, though) --
    never occurred to me that encoding was the problem. Anyway, it's sorted,
    thanks.
    Jay, Jan 8, 2004
    #9
  10. Jay

    Jay Guest

    "rf" <> wrote in message
    news:4FSKb.81881$...
    >
    > PLEASE do not post in HTML!


    If you read what I posted, you saw that it was the only way to show what was
    being displayed in my browser, which was the point; I didn't use HTML in my
    other posts, did I? Clinging to some "no HMTL posting under any
    circumstances" credo is, at best, impractical and, at worst, pedantically
    purist.
    Jay, Jan 8, 2004
    #10
  11. Jay wrote:

    > "rf" <> wrote in message
    > news:4FSKb.81881$...
    >>
    >> PLEASE do not post in HTML!

    >
    > If you read what I posted, you saw that it was the only way to show what was
    > being displayed in my browser


    A better way would be to post the URL of a sample page exhibiting the
    problem along with the URL for a screenshot of how IE 6 rendered the page
    and another URL for a screenshot of how you expected it to be rendered.

    --
    Toby A Inkster BSc (Hons) ARCS
    Contact Me - http://www.goddamn.co.uk/tobyink/?page=132
    Toby A Inkster, Jan 8, 2004
    #11
  12. Jay

    rf Guest

    "Jay" <> wrote in message
    news:3ffcaa1b$0$32587$...
    > "rf" <> wrote in message
    > news:4FSKb.81881$...
    > >
    > > PLEASE do not post in HTML!

    >
    > If you read what I posted, you saw that it was the only way to show what

    was
    > being displayed in my browser, which was the point; I didn't use HTML in

    my
    > other posts, did I? Clinging to some "no HMTL posting under any
    > circumstances" credo is, at best, impractical and, at worst, pedantically
    > purist.


    You do realise that many news hosts disregard any post containing HTML?

    Cheers
    Richard.
    rf, Jan 8, 2004
    #12
  13. Jay

    Jay Guest

    "Toby A Inkster" <> wrote in message
    news:p...
    >
    > A better way would be to post the URL of a sample page exhibiting the
    > problem along with the URL for a screenshot of how IE 6 rendered the page
    > and another URL for a screenshot of how you expected it to be rendered.


    I suppose if you're a member of the "no HMTL posting under any
    circumstances" club, that would be better. I explained how it should've
    appeared in case it didn't appear correctly; it hardly merited the effort
    you suggest. One is obviously free to follow one's non-HTML-posting dogma,
    but I'll decide when I feel an HTML post is appropriate, thanks.
    Jay, Jan 9, 2004
    #13
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    5
    Views:
    738
  2. =?Utf-8?B?QmFobWFu?=

    Bizarre behavior

    =?Utf-8?B?QmFobWFu?=, Mar 3, 2006, in forum: ASP .Net
    Replies:
    2
    Views:
    398
    =?Utf-8?B?QmFobWFu?=
    Mar 6, 2006
  3. Pete Jereb

    bizarre behavior using .lstrip

    Pete Jereb, Sep 20, 2003, in forum: Python
    Replies:
    8
    Views:
    334
    Peter Hansen
    Sep 20, 2003
  4. Replies:
    0
    Views:
    508
  5. Replies:
    5
    Views:
    164
    Öö Tiib
    Jun 15, 2013
Loading...

Share This Page