2011-01-22

what's the de facto practice on ampersand encoding in html

http://stackoverflow.com/questions/4768391/whats-the-de-facto-practice-on-ampersand-encoding-in-html

by html spec, ampersand should be encoded as

&

but of course a lot web doesn't do that. Here's a example of ad widget from amazon:

src="http://rcm.amazon.com/e/cm?t=xyzxyz-20&o=1&p=11&l=ur1&category=textbooks&banner=17P1AE8RQ1T7ZFC62V82&f=ifr"
width="120"
height="600"
scrolling="no"
border="0"
marginwidth="0"
style="border:none;"
frameborder="0">


note that the ampersand is not encoded.

My question is, for those work a lot with commercial sites, work in a company, or work with many widget codes, do most of these sites actually encode the ampersand?

(in other words, what percentage of top 1k sites try to encode ampersand properly when it is in url?)

No comments:

Post a Comment