How to learn java script?

Dana Gallagher

Name was Missygail
Joined
Jun 8, 2003
Posts
3,887
Hello to all my tech and html guru's out in the world of literotica. I'm back to ask yet another technical question.

I'm in class for web site design and web programming. I feel I'm doing good in both courses, though I'm wanning a bit in programming class. We are doing java script and it is so confusing for me that I feel physically sick each time I look at it. We are doing functions and it's so much like math that I feel I might break out in hives.

We are studing out of a book created by CIW. This book is so dry and they really want you to work out the functions yourself rather than "type this, get this'.

Anyone know of a better book? Something that can help me learn java script a bit better. I don't want to mess up this class. I know that learning java script can be a big help in the world of web design. I do want to learn it, but first I need to understand it without getting a head and gut ache.

Please don't suggest java script for dummies. I've done some of the dummy bookes for html other things and I don't care for them much.
 
ok.... start practicing the stuff over and over.... backwards and forwards... learn each individual function and what not then toy with it till you fully comprehend the intricacies...
 
biggsmall0669 said:
ok.... start practicing the stuff over and over.... backwards and forwards... learn each individual function and what not then toy with it till you fully comprehend the intricacies...
I hope that will help. The other day I was doing class work and we working with While functions. The book told me to put in a isNaN statement. I freaked I didn't know what it was or what it did or why it was there. I searched the book trying to find out what it was... I googled it and felt stupid when they told me it was basically saying "While is not a number. "

I'm trying to get it all down. :confused:
 
Have you worked through a good number of the java script how to/tutorial sites? It looks like there are plenty that use the "type X, get Y" format and plain explanations out there.

Google 'Java script How To' and 'Tutorials' and start combing through the results.

I'd also suggest searching for tutorials on the specific subjects you're working on in class and that are mentioned in the book. For example, if you had a chapter or assignment on creating scrolling text with java, you could search for 'java script scrolling text.'

Additional options:
-Seek out one or more students who are doing well in the class for a study buddy/group, or even just to help you on the more difficult conepts

- Talk to your Instructor and/or TA. I've found most are more than happy to give students extra help.

- Find a tutor. Other students often work at very reasonable rates, and you may only need an hour or two a week to excel if you're willing to figure out as much as you can on your own. Your instructor or the department may be able to give you recommendations, and you can also advertise on bulletin boards, in the job center, on sites like Craigslist, etc.
 
Last edited:
missygail said:
Anyone know of a better book? Something that can help me learn java script a bit better.

This isn't js specific, but I'v found it a tremendously useful book for understanding ANY programming language/scripting: Program Design with Pseudocode

It's out of print, but the amazon link has links to sources for second-hand copies.
 
Well....

Well i Dont Know Much But....Check Out This Awesome Site If Recently Put Up And It "ROCKS!" :nana:
 
there is a wonderful tutorial put out by w3c schools here is the linkclick here

you can learn java script among lots of others and even get certified!
 
I myself have not put in nearly as much effort towards learning Java as I should, but there are three basic things I would suggest (drawing from my experiences and my problems, ymmv):

1) Planning/pseudocode. It's much easier to program stuff if you work out beforehand how you want it to work. One benefit is if you're not sure how to make something work (e.g. imagine you want something to happen repeatedly, but you don't know the syntax or specifics of loops), you should run into the problem while pseudocoding, and you can highlight it and look it up before you start writing the program in proper. Which leads me to...

2) Google. You can probably find just about everything you want by searching. I try not to do it while frustrated that something's broken though. I find that looking through tutorials and pages of code while irritated tends to get me nowhere or frustrate me further, even when the resources are good, so I absolutely have to leave it for a while before trying to fix it. This could be idiosyncratic.

3) Play with the code. You probably hear this all the time, and I know I didn't really buy it at first, but it is infinitely more difficult to learn to code from theory than by actually writing it up and compiling it yourself. It also helps build some confidence, as you get a little psychological reward every time your program compiles, and you learn the syntax more precisely, get in a habit of using your semicolons all the time, and so on.

Hopefully that's not too redundant with what others have said or insultingly simple or anything.

Oh, and as for the mathy-ness... it's hard to get rid of it entirely (computers are, after all, very complex calculators more than anything else), but pseudocode is a little more like English, and you can do all of the real thinking at that stage. The inevitably mathematical-feeling "real" code can be churned out a little more mindlessly, so maybe that will help you distance yourself it a little bit.
 
MISSYGAIL

I've been fooling with computers since 1978.

Two things helped me alot more than classes and books.

ONE: Get involved with some smart hackers and experimenters.

TWO: Play with the computer code all the time. Immerse yourself in it.
 
MATH

I took geometry in high school. At the end of the course I still didnt know my ass from my elbow. A few years later I studied geometry with a genius who knew how to teach what he knew. It was sooooo easy. There really are people who can make tough subjects into almost baby-stuff.
 
missygail said:
I'm in class for web site design and web programming. I feel I'm doing good in both courses, though I'm wanning a bit in programming class. We are doing java script and it is so confusing for me that I feel physically sick each time I look at it. We are doing functions and it's so much like math that I feel I might break out in hives.

We are studing out of a book created by CIW. This book is so dry and they really want you to work out the functions yourself rather than "type this, get this'.

Anyone know of a better book? Something that can help me learn java script a bit better. I don't want to mess up this class. I know that learning java script can be a big help in the world of web design. I do want to learn it, but first I need to understand it without getting a head and gut ache.

First thing first. It's "**********",[1] not "Java Script." That's important for Googling and because ********** is nothing like Java, as someone incorrectly implied. The two languages have nothing in common.

Second, is this your first programming language? (X)HTML and CSS are nice, but they're markup (formatting) languages, not programming ones. No variables, no functions, just simple straightforward execution. If it is, a big part of the problem might be learning how to think like a programmer, how to break things up into steps, how to organize the steps in to functions, what to keep track of, etc.

I've been programming for so long, that I can't give you any advice on a beginning ********** book. I'd suggest going to your local Borders/Barnes & Noble and flipping through their selection.

[1] Hmmm, I obviously mean "java" and "script" written as one word, but the BB software is censoring it. I guess that explains why everyone was using two words.
 
Last edited:
Sitepoint is a great forum for some code languages including the link to the js forum.

Take a look in your college library and see what there is available in js.

Ask your teachers etc about knowledgeable folks who've written books about it and would they recommend one?

Generally I have found the Sams Teach Yourself books pretty good as well as the Bible series of books on different computer subjects.
 
bighornedsatyr said:
First thing first. It's "**********",[1] not "Java Script." That's important for Googling and because ********** is nothing like Java, as someone incorrectly implied. The two languages have nothing in common.

Second, is this your first programming language? (X)HTML and CSS are nice, but they're markup (formatting) languages, not programming ones. No variables, no functions, just simple straightforward execution. If it is, a big part of the problem might be learning how to think like a programmer, how to break things up into steps, how to organize the steps in to functions, what to keep track of, etc.

I've been programming for so long, that I can't give you any advice on a beginning ********** book. I'd suggest going to your local Borders/Barnes & Noble and flipping through their selection.

[1] Hmmm, I obviously mean "java" and "script" written as one word, but the BB software is censoring it. I guess that explains why everyone was using two words.

Sorry I'm not replying in order but I had to reply to this one first. Yeah I know how it's spelled, without the space... but it was censored as you found out.

Yes, I'm not doing Java, I'm doing Java(no space)Script. I know the differences between Java and Java(no space)Script, I'm in school so we've studied the differences. Java(no space)Script was made by Netscape and was originally called LiveScript. Java was created by Sun Microsystems. They teamed together to call it Java(no space)Script mostly because of the popularity of Java and nothing to do with any similarity between the two languages.

Yes, this would be my first programming language. I've learned html, xhtml, and a little bit of CSS. I don't know how to think like a programmer....

What it is that I need a book that basically says type this to get this. I'm working out of CIW Java(No Space)Script Fundamentals Academic Student Guide.

My teacher actually gave us the script... for a Java(no space)Script quiz. It took me forever to just copy the script right, to make it work. I actually had to get help from another boy in the class to just get that right.

I don't want to give up on this. I want to figure it out somehow.

So far all I've been able to do one thing with Java(no space)Script and all that was, was putting my own goofy stuff into something the teacher created.

http://star.walagata.com/w/missygail/button_of_death.html

I guess I'll go and see what Amazon has to offer. I was hoping someone could just say "Hey this book worked great for me, go buy it."

My sister is sending me a new computer soon. Hopefully that will allow me the ability to go hide and try to learn this stuff. Where I live, it's hard to get away and study... not to mention being a single mother of three.
 
http://www.lynda.com

has a quicktime video on Java(no space)Script that you can order but it's $99.99 Though I might just save up to try and get it or con another teacher into getting it and letting me use borrow it for awhile.
 
SweetErika said:
Have you worked through a good number of the java script how to/tutorial sites? It looks like there are plenty that use the "type X, get Y" format and plain explanations out there.

Google 'Java script How To' and 'Tutorials' and start combing through the results.

I'd also suggest searching for tutorials on the specific subjects you're working on in class and that are mentioned in the book. For example, if you had a chapter or assignment on creating scrolling text with java, you could search for 'java script scrolling text.'

Additional options:
-Seek out one or more students who are doing well in the class for a study buddy/group, or even just to help you on the more difficult conepts

- Talk to your Instructor and/or TA. I've found most are more than happy to give students extra help.

- Find a tutor. Other students often work at very reasonable rates, and you may only need an hour or two a week to excel if you're willing to figure out as much as you can on your own. Your instructor or the department may be able to give you recommendations, and you can also advertise on bulletin boards, in the job center, on sites like Craigslist, etc.

I've been through some of the online tutorials. That's where I had to find what that dang isNaN meant... I can try advertising, I'm not socialible enough to ask for help from other students.
 
ms.read said:
there is a wonderful tutorial put out by w3c schools here is the linkclick here

you can learn java script among lots of others and even get certified!

I've been there a few times. I think my teacher even steals some text from that site for his power point shows...
 
Ermend said:
I myself have not put in nearly as much effort towards learning Java as I should, but there are three basic things I would suggest (drawing from my experiences and my problems, ymmv):

1) Planning/pseudocode. It's much easier to program stuff if you work out beforehand how you want it to work. One benefit is if you're not sure how to make something work (e.g. imagine you want something to happen repeatedly, but you don't know the syntax or specifics of loops), you should run into the problem while pseudocoding, and you can highlight it and look it up before you start writing the program in proper. Which leads me to...

2) Google. You can probably find just about everything you want by searching. I try not to do it while frustrated that something's broken though. I find that looking through tutorials and pages of code while irritated tends to get me nowhere or frustrate me further, even when the resources are good, so I absolutely have to leave it for a while before trying to fix it. This could be idiosyncratic.

3) Play with the code. You probably hear this all the time, and I know I didn't really buy it at first, but it is infinitely more difficult to learn to code from theory than by actually writing it up and compiling it yourself. It also helps build some confidence, as you get a little psychological reward every time your program compiles, and you learn the syntax more precisely, get in a habit of using your semicolons all the time, and so on.

Hopefully that's not too redundant with what others have said or insultingly simple or anything.

Oh, and as for the mathy-ness... it's hard to get rid of it entirely (computers are, after all, very complex calculators more than anything else), but pseudocode is a little more like English, and you can do all of the real thinking at that stage. The inevitably mathematical-feeling "real" code can be churned out a little more mindlessly, so maybe that will help you distance yourself it a little bit.

No you haven't been too redundant or insultingly simple. Right now I feel fairly simple. I thought I knew something until I hit Java(no space)Script... no I realize my brain is full of mush.

I know I like html. I've created a whole website with html. I do like finding the end result... and knowing I did it right and it looks good.

I'm hoping that when I get a new computer from my sister that I'll be able to relax and just try to learn Java(no space)Script
 
missygail said:
I've been through some of the online tutorials. That's where I had to find what that dang isNaN meant...

I know you said in your first post that the ...For Dummies series hasn't been much help in the past, but I've found them to be excellent quick references for looking up things like "isNaN" and the syntax for using it.

missygail said:
Yes, this would be my first programming language. ... I don't know how to think like a programmer....

The book on program design I suggested earlier is intended for people like you -- it teaches "thinking like a programmer." It's a bit of extra study (130 pages or so) that isn't directly applicable to the class you're taking, but it WILL make that class easier -- and every other programming/webdesign class to follow. The first chapter "Introdution to Problem Solving" may be all that you need.
 
dora123 said:
Oh yeah, I think it's helpful. Practicing is a good way
I want to do this... it's difficult. I have three children and I live with my parents. Getting time to practice anything is difficult. I mostly get on the computer at night and by then if I even attempt to pick up a ********** book I'll pass out where I sit.

I'm on right now because it's directly after school and my children are still in daycare for the moment.

I'm not making excuses, this is just my reality. I'm hoping my sister will send me a computer soon, which I can hook up into my bedroom and escape from parents, children, and the T.V.'s that never seem to shut off. Though of course when I run off to my bedroom to learn my father will accuse me of not paying attention to my children then give me a guilt trip that he never gets to talk to his daughter anymore! *sigh* :rolleyes:
 
Weird Harold said:
I know you said in your first post that the ...For Dummies series hasn't been much help in the past, but I've found them to be excellent quick references for looking up things like "isNaN" and the syntax for using it.



The book on program design I suggested earlier is intended for people like you -- it teaches "thinking like a programmer." It's a bit of extra study (130 pages or so) that isn't directly applicable to the class you're taking, but it WILL make that class easier -- and every other programming/webdesign class to follow. The first chapter "Introdution to Problem Solving" may be all that you need.
I'll check into the book you mentioned and yeah I think I'm gonna need that introduction to problem solving... I was thinking of going up to Barns and Nobles to look around today.

I'm gonna end up with an ulcer by the time this class is done and my teacher doesn't really care much. I ranted about it in my myspace blog, so I'll save you all my mad ravings.

I'll check into some dummie books for Java(no space)Script... Maybe I'll make it through this class. Though after this we are going into PHP!!! yay!
 
Ha!

Too bad they don't have a Java(no space)Script book for the A.D.D. adult, maybe then I could make sense of this nonsensical 'language'. :nana:
 
Hopefully...

Ordered and ordered. Purchased JS for dummies and Program Design With Pseudocode. Hopefully they arrive before I'm done with this portion of my class. Until, I have to start worrying about PHP for this dummy.
 
missygail said:
Ordered and ordered. Purchased JS for dummies and Program Design With Pseudocode. Hopefully they arrive before I'm done with this portion of my class. Until, I have to start worrying about PHP for this dummy.
I think scripting languages are generally more difficult to learn because they aren't compiled and often your only indication of programming errors is that your program just doesn't work. Compiled languages fail to build and makes it easier to detect things like missing semicolons, slight spelling differences (e.g. var myVar; vs var myvar; etc.) A newbie will waste a lot of time trying to figure out why their program isn't working as expected when they should be spending time on thinking about the actual problem and its programming solution.

Introductory programming books and tutorials don't spend enough time teaching basic debugging techniques which makes it hard for beginners to find coding errors.

One useful thing for java**script in particular is to use alert statements in your code which pop up a dialog that will indicate how far your script has run before failing, and can also display values that are important do debugging your code.

For example

function myFunction () {
alert ('here 1');
var myNumber = 123;

myNumber += 2
// mynumber += 2;

alert('myNumber = ' + myNumber);
}

In this case, when you execute this code, you'll get a popup dialog with the text 'here 1', and you'll know that you're code ran correctly to that point Nothing else will happen so you know the coding error occurred between the first and second alert statement. Examination of the code reveals that the myNumber += 2 is missing a semicolon. As another example, by commenting out the first myNumber statement and uncommenting the second, the second alert will display 'myNumber = 123' which isn't the value we were expecting for myNumber because the variable names are different. Had this been a compiled language like C++, C#, or even VB.net with the proper compiler settings, both the missing semicolon and variable naming difference would have caused compiler errors or warnings which are much more easily corrected than runtime errors.

JAMESBJOHNSON is correct that you should immerse yourself in programming. The fundamentals of programming are the same for just about any programming language and after a point, it becomes fairly easy to move between different languages.
 
brazhunter said:
I think scripting languages are generally more difficult to learn because they aren't compiled and often your only indication of programming errors is that your program just doesn't work.

Not necessarily true. Firefox has a built in Error return (Tools > Error Console) that can be helpful for identifying the line where your code is faulting. While not as good as a compiler, it does help a bit when you're pushing lots of JS at one time.

Personally, I've always found that the best way to learn any language is by exploring the ways in which other people use it. Reading tutorials is good and all, but if its simply telling you what to write line by line, you aren't going to retain that information.

Try getting a copy of "Java_Script: A Beginner's Guide" by John Pollock. It's a really great starting point for someone who has minimal OOP (object oriented programming) experience and is easy to read compared to a lot of other books I've read on coding. Grab that book and just head to some of your favorite websites, view the source and see if they're using any JS on their pages. Try to decipher the code on your own, and then try to implement it on some 'dummy' pages afterwards.

You can sit and read books and tutorials till the cows come home, but you're going to have to get dirty if you want to be able to use any language effectively.

Good luck! Don't let yourself get discouraged, it's not an easy task and you wont get much praise from your non-programmer friends. A good piece of code never impresses the average Joe, it just works. ;)
 
thus far we've completed the lesson on Java*Script. I got a B on the final 80%.


I turned in 7 out of 10 chapters in Java*script.... I think that's good enough to pass this nine weeks. We are on to PHP now... I'm scared. :confused:
 
Back
Top