Re: img issue: should we restrict the URI

> "but it seems that a number of web developers not only produce  
> markup like this but notice the requests in their HTTP logs and file  
> bugs about it."


This happened a lot to me recently during the early to mid-development  
stages of a few sites.

The html validator didn’t notify me of an img tag with no src value  
and even if it die I wouldn't have cared
because it happened when I was mostly focusing on server side code to  
manage content.
So at the time the validity of the html and image sources weren’t my  
primary concern.

I only noticed because when loading that page should result in 1 new  
record in the database I got 5 new records instead.
This happened because I had 4 empty img tags in my template.
Each one causing the browser to call the page url 4 additional times :(

Took me an hour to realize the problem was the browser and not my  
code :(


On Dec 2, at 10:48 AM, Boris Zbarsky wrote:

> 3)  In practice sites somewhat commonly have <img src="">.  We (Gecko)
>    have had 28 independent bug reports filed (with people bothering to
>    create an account in the bug database, etc) about the behavior
>    difference from IE here.  That's a much larger number of bug
>    reports than we usually get about a given issue.  I can't tell you
>    why this pattern is so common (e.g. whether some authoring
>    frameworks produce it in some cases), but it seems that a number
>    of web developers not only produce markup like this but notice
>    the requests in their HTTP logs and file bugs about it.

::   thyme online ltd
::   po box ap 59223-317  nassau,  the bahamas
::   website: http://www.thymeonline.com/
::   tel: +1 242 677-5733

Received on Friday, 9 January 2009 08:38:31 UTC