eldan88 Posted November 12, 2013 Share Posted November 12, 2013 Hey Guys, I am new to java, and was looking into the getElementsByTagName functionality. Every time I use that method, I get the following error message on my firebug console message "ReferenceError: consloe is not defined var myLinks = document.getElementsByTagName("a") " Below is my code. Any help would be highly appreciated! var myLinks = document.getElementsByTagName("a"); consloe.log ("Links", myLinks.length); Link to comment https://forums.phpfreaks.com/topic/283854-need-help-with-getelementsbytagname/ Share on other sites More sharing options...
dalecosp Posted November 12, 2013 Share Posted November 12, 2013 You spelled "console" wrong --- and "consloe" isn't defined. Link to comment https://forums.phpfreaks.com/topic/283854-need-help-with-getelementsbytagname/#findComment-1458056 Share on other sites More sharing options...
dalecosp Posted November 12, 2013 Share Posted November 12, 2013 Incidentally, this is Javascript, which is NOT Java.Search Youtube for Douglas Crockford and spend about 3 hours on his tutorial series from Yahoo! It will help a lot. Link to comment https://forums.phpfreaks.com/topic/283854-need-help-with-getelementsbytagname/#findComment-1458057 Share on other sites More sharing options...
Irate Posted November 13, 2013 Share Posted November 13, 2013 Better yet, if you're looking for an extensive, intricate book on JavaScript, check out David Flanagan's JavaScript: The Definitive Guide (it's around 60$ or 42€, but it is worth it, plus, it has cheaper, digital copies). Link to comment https://forums.phpfreaks.com/topic/283854-need-help-with-getelementsbytagname/#findComment-1458099 Share on other sites More sharing options...
eldan88 Posted November 13, 2013 Author Share Posted November 13, 2013 Thanks guys! I was really tired when I wrote this post, guess that's why i didn't see that misspelling. Link to comment https://forums.phpfreaks.com/topic/283854-need-help-with-getelementsbytagname/#findComment-1458119 Share on other sites More sharing options...
dalecosp Posted November 13, 2013 Share Posted November 13, 2013 Thanks guys! I was really tired when I wrote this post, guess that's why i didn't see that misspelling. It happens to everyone at some point or another. Get some sleep before coding whenever possible! ;-) Link to comment https://forums.phpfreaks.com/topic/283854-need-help-with-getelementsbytagname/#findComment-1458137 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.