On 28 Jun 2013 at 22:28, Zirak A <zi...@mail.com> wrote: > Because they may result in the same thing, but they have different semantic > meanings. I want to get an element by its id, not run a CSS selector. I want > to get elements by their tag names, not run a CSS selector.
Quite so. > From: Tab Atkins Jr. > Given that you have querySelector, why would you want the other > functions? getElementById("foo") is just querySelector("#foo"), > getElementsByTagName("foo") is just querySelectorAll("foo"), etc. In addition it's hardly obvious that this is what you do. -- Cheers -- Tim