Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > HTML > Bizarre display behavior with "+" and "-" signs in IE 6.0 only

Reply
Thread Tools

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

 
 
Jay
Guest
Posts: n/a
 
      01-07-2004
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


 
Reply With Quote
 
 
 
 
Jay
Guest
Posts: n/a
 
      01-07-2004
> (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")
 
Reply With Quote
 
 
 
 
John McGaw
Guest
Posts: n/a
 
      01-07-2004
"Jay" <(E-Mail Removed)> wrote in message
news:3ffb5b16$0$32589$(E-Mail Removed) m...
> 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

 
Reply With Quote
 
Jay
Guest
Posts: n/a
 
      01-07-2004
"John McGaw" <(E-Mail Removed)> wrote in message
news:15JKb.259$(E-Mail Removed)...
>
> 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


 
Reply With Quote
 
Mark Parnell
Guest
Posts: n/a
 
      01-07-2004
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
 
Reply With Quote
 
Jay
Guest
Posts: n/a
 
      01-07-2004
"Mark Parnell" <(E-Mail Removed)> wrote in message
news:65vmxlv0y8tr$.xg7ey4mf6x8y$(E-Mail Removed)...
>
> 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


 
Reply With Quote
 
rf
Guest
Posts: n/a
 
      01-07-2004

"Jay" <(E-Mail Removed)> wrote in message
news:3ffb5ca0$0$32586$(E-Mail Removed) m...
> (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!


 
Reply With Quote
 
Jukka K. Korpela
Guest
Posts: n/a
 
      01-07-2004
"Jay" <(E-Mail Removed)> 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


 
Reply With Quote
 
Jay
Guest
Posts: n/a
 
      01-08-2004
"Jukka K. Korpela" <(E-Mail Removed)> 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.


 
Reply With Quote
 
Jay
Guest
Posts: n/a
 
      01-08-2004
"rf" <(E-Mail Removed)> wrote in message
news:4FSKb.81881$(E-Mail Removed)...
>
> 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.


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Bizarre behavior =?Utf-8?B?QmFobWFu?= ASP .Net 2 03-06-2006 07:10 PM
bizarre server.transfer behavior ChaunceyMo@gmail.com ASP .Net 5 11-15-2005 11:18 PM
Bizarre behavior by FireFox 1.0.7 Gerald Orvis Davis Firefox 2 11-07-2005 07:53 AM
Cisco 837 bizarre behavior Kapamarou Cisco 2 01-05-2004 10:31 AM
bizarre behavior using .lstrip Pete Jereb Python 8 09-20-2003 07:47 PM



Advertisments