Jump to content
Larry Ullman's Book Forums

Daniel Leavey

Members
  • Content Count

    4
  • Joined

  • Last visited

Community Reputation

1 Neutral

About Daniel Leavey

  • Rank
    Newbie
  1. The Switch Conditional exercise on pages 143 - 150 makes us of an undefined variable, var cost; and I'm not sure what role it plays in the code. Do the cost elements in the switch statements load the value into the undefined variable var cost depending upon which condition is met in the document's type value? I can remove these two lines of code, as well as the undefined variable, var cost, and still see the membership form run: var type = document.getElementById('type'); var years = document.getElementById('years'); Why did we create a reference to the document element years when it seems not to be used in the script? Many mysteries have unfolded in this exercise.
  2. There you go. Thanks, Edward. I didn't know that innerText and innerHTML were interchangeable. I really do have to put aside Tim Wright's "Learning Javascript." It has befuddled my mind. Pollocks 3rd edition (now ancient) did a lot more to introduce me to JavaScript, and I'm hoping Larry's book will help me to make the real-world connection to interactivity. I think this forum is also going to be very, very helpful.
  3. I have to say, I've found learning JavaScript one of the hardest tasks in building my web design/development skills. Some of the books are riddled with coding errors, and some have no errata page online. Others, like the one I was reading prior to Larry Ullman's book, referred to the"innerHTML DOM method". In any case, I am still not clear as to why "innerHTML" was not covered in Mr. Ullman's book.
  4. I've noticed that the book doesn't include any discussion of the innerHTML DOM method. Is there a reason for its exclusion, or has the method been replaced some more modern technique? Thank you.
×
×
  • Create New...