November 5th 2009

Confusing bugs

I love bugs that are just confusing and/or break your mental model of how you think the software works.

Here is a good example: Given the following HTML in Gecko, what happens when a user clicks the button?

<form method="POST" action="/form-action">
  <a href="/anchor-target">
    <input type="button" value="harro">
  </a>
</form>
GET /anchor-target HTTP/1.1
GET /anchor-target HTTP/1.1

2 GET requests? Okay, perhaps some sort of event bubbling problem; it's relatively common in GUI internals. But what about:

<form method="POST" action="/form-action">
  <a href="/anchor-target">
    <input type="image" src="http://upload.wikimedia.org/wikipedia/en/7/75/LHC5.jpg">
  </a>
</form>
POST /form-action HTTP/1.1
GET /anchor-target HTTP/1.1
GET /anchor-target HTTP/1.1

Wait, this time it POSTs the form and makes 2 GET requests?

Answers in a Bugzilla report, thanks.




You can subscribe to new posts via email or RSS.