I’m sure everyone knows this but me, so bare with me, but did you know that #PageElementName in the browser goes to the element with the ID PageElementName? We all know the stupid <a name="PageElementName" /> business, but it seems like the browser goes to the ID if it can’t find something with that name.
I was passing some commands in the query-string for an Ajax application I was writing when I noticed that whenever I passed #transcript, it was scrolling down the page. I should really read a book on web-browsers or something. [END TRANSMISSION]
Dang. The things you learn. Thanks!
The name attribute has been “formally deprecated, and will be removed in a subsequent version of XHTML.” According to the W3C.
I was tired of giving input fields name and id
Thanks, Paul!
This behaviour was built into HTML from its inception, actually.
getElementById is your friend. Pretty amsuing, though, that loads of people are messing with this “AJAX” voodoo without a basic grasp of the DOM.
What scares me is that everyone is messing around with DHTML and Ajax without a basic knowledge of O-O. Just wait for the function collisions