New ask Hacker News story: Beware of the Unicode no-break space (0xC2 0xA0) - Gadgets180™

It is a technical blog/website and you will get here all the technical stuff and we also post some tech news.

Header Ads

Post Top Ad

Responsive Ads Here

New ask Hacker News story: Beware of the Unicode no-break space (0xC2 0xA0)

Share This
Beware of the Unicode no-break space (0xC2 0xA0)
2 by vicjicama | 0 comments on Hacker News.
Hi all! Yesterday I saw a very strange behavior while working with some tags, I thought this was a bug! Can you spot the difference? (https://ift.tt/3isdhQh)
the other ( https://ift.tt/3x3gN97 )
Both looks exactly the same!, but only one is working.... It turn out that it was an unicode character issue, the spacing between the non working tag was using the unicode non-breaking space (0xC2 0xA0), when I replaced the spaces with the regular space character (0x20) everything worked again. I think that I copied this tag from an email, I will be extra careful in the future for this kind of issues. It took me a while to find out this, I hope this could help anyone, if your attributes are null and you are sure that they are present check you html with a hex editor. Let me know your thoughts

Don't forget to subscribe our youtube channel Click here:- http://www.youtube.com/c/techgk Product of the day

No comments:

Post a Comment

Post Bottom Ad

Responsive Ads Here

Pages