heretolearn — 2014-02-22T15:31:53-05:00 — #1
Can someone please explain to me the difference between
Notice that there are no quotes within the first document block.
felgall — 2014-02-22T16:07:19-05:00 — #2
$(document) passes the document element to JQuery.
$('document') passes the CSS selector 'document' to JQuery.
Neither is necessary as the ready method in jQuery should no longer be called directly.
You should either use:
and so run the code straight away without needing to test ready.
heretolearn — 2014-02-22T16:11:13-05:00 — #3
thank you for the detailed explanation