Learning Javascript on OS X

Discussion in 'Buying Tips, Advice and Discussion (archive)' started by pjkelnhofer, Jan 29, 2004.

  1. pjkelnhofer macrumors 6502a

    pjkelnhofer

    Joined:
    Sep 8, 2003
    Location:
    Boston
    #1
    Any one out there who can recommend a good book to teach me Javascript on OS X (possibly another one to teach Java 2 as well) ?

    I would rather not have to use my finacee's Dell for this and I really want to learn it (all the books at Barnes & Nobles were specifically written in Windows).
     
  2. Nermal Moderator

    Nermal

    Staff Member

    Joined:
    Dec 7, 2002
    Location:
    New Zealand
    #2
    I'm no JavaScript expert, but I didn't think there was anything Windows-centric about it. It was invented by Netscape, and as far as I know, it's platform- and browser-independent (just sits inside an HTML file I believe). What do you mean when you say the books are written for Windows?
     
  3. Westside guy macrumors 601

    Westside guy

    Joined:
    Oct 15, 2003
    Location:
    The soggy side of the Pacific NW
    #3
  4. pjkelnhofer thread starter macrumors 6502a

    pjkelnhofer

    Joined:
    Sep 8, 2003
    Location:
    Boston
    #4
    Basically, the books come with some programs to that go along with it that only run on Windows.

    I only read the back of the book and I assumed you needed the programs for compiling, etc. Keep in mind I haven't really done any programming since I took C in college ten years ago.
     
  5. Westside guy macrumors 601

    Westside guy

    Joined:
    Oct 15, 2003
    Location:
    The soggy side of the Pacific NW
    #5
    JavaScript is platform independent - although Microsoft's "JScript" is JavaScript plus a few silly extensions.

    If this book truly is "Windows-only JavaScript" it's a really BAD idea. Don't use that.
     
  6. edesignuk Moderator emeritus

    edesignuk

    Joined:
    Mar 25, 2002
    Location:
    London, England
    #6
    JavaScript is not Java. The two are completely different. Both can be written on anything and are cross platform.
     
  7. pjkelnhofer thread starter macrumors 6502a

    pjkelnhofer

    Joined:
    Sep 8, 2003
    Location:
    Boston
    #7
    I understand that. I would like to try to learn both (all though JavaScript is more important to me). I just want a book that is written for a Mac user. Not one that comes with CD contain some Windows freeware or one that at anypoint to go the "Start Menu". All the books I have seen assume you are using a Windows PC.
     
  8. mykemp macrumors newbie

    Joined:
    Dec 10, 2003
    Location:
    Richmond, VA
    #8
    I'm not a real JavaScript expert either, but as was mentioned JavaScript is not Java, and it should be platform independant.

    That said, here are somethings to watchout for.

    1) JavaScript might not be able to be interpreted by all browsers when writing web apps. (ie. Lynx or other text based browsers). That is it's one limitation since it's interpreted, is how the browser interprets, and processes the commands.

    2) There might be some books out there geared towards windows JavaScript implementation using WSH (Windows Script Host). This is that little engine that Micro$oft invented to make Network/Desktop Admin's jobs easier through automation... it can process JavaScript or VBScript, even PERL and TCL if you add the plugins. WSH is nice for windows, but this is the same pandora's box that causes a lot of the vulnerabilities with Worms. Since this a Mac forum, I'll end my WSH talk there.

    3) JavaScript can be used on the Mac with a program called Konfabulator. I'm a Mac newbie myself, and haven't had much experience with Konfabulator, but from what I understand you can write your own widgits using JavaScript and XML, and Konfabulator will act as the interpreter. I'm sure more information can be found on this on this site or by doing a google on Konfabulator.

    All that being said, I recomend O'Reilly's JavaScript the Definative Guide, and I recommend going out to a site like hotscripts.com or webmonkey.com, getting some good sample scripts and ideas, tweaking them, playing and learning.

    See ya,

    Myron
     
  9. jeremy.king macrumors 603

    jeremy.king

    Joined:
    Jul 23, 2002
    Location:
    Fuquay Varina, NC
    #9
    You could always compile your own JS interpreter.

    http://www.mozilla.org/js/spidermonkey/

    :eek:

    But everyone is right, to learn javascript you can use any text editor to create an HTML page that contains your scriptlets. Preview these in a good standards based browser, such as Mozilla, and I believe there is a javascript debugger built in to help you trouble shoot code.

    You may still need a Windows PC or VPC to test other browser variants as they are not all the same.

    I highly recommmend
    this book which documents what functions work in which browsers. Also has HTML, CSS and DOM specs. Its more of a reference than a tutorial, however, but should be in every web programmers library, IMO.
     
  10. mykemp macrumors newbie

    Joined:
    Dec 10, 2003
    Location:
    Richmond, VA
    #10
    I'm glad you recommended that book! I saw it on O'reilly's site, and I usually like there stuff, and I added it to my Amazon Wish List. Maybe I'll splurge and get it for myself.

    Myron
     
  11. zoetropeuk macrumors regular

    Joined:
    Dec 19, 2002
    Location:
    Oxford UK
    #11
    You should download and install the lastest copy of Netscape as it contains one of the only javascript debuggers available on the Mac.
     
  12. whafrog macrumors newbie

    Joined:
    Jan 30, 2004
    #12
    javascript book

    >Any one out there who can recommend a good book to teach
    >me Javascript on OS X (possibly another one to teach Java 2
    >as well) ?

    Any javascript book will do. Don't bother buying one with a CD, you are paying for something you will never use.

    I like O'Reilly's books, especially JavaScript and DHTML Cookbook (
    http://www.amazon.com/exec/obidos/A...5485297/sr=2-2/ref=sr_2_2/104-4617345-8455911 )

    but you might want to start with Javascript: The definitive guide ( http://www.amazon.com/exec/obidos/A...5485404/sr=2-1/ref=sr_2_1/104-4617345-8455911 )

    Important: if you are going to do any serious javascript, use a browser that helps you. Mozilla has a great debugger that is very helpful. IE's javascript error messages will send you screaming into the night! :)
     
  13. jeremy.king macrumors 603

    jeremy.king

    Joined:
    Jul 23, 2002
    Location:
    Fuquay Varina, NC
    #13
    Any reason you don't want to order from bookpool.com? Generally I find them cheaper than amazon, same free shipping too.

    I think its a great resource for tech books, but its my opinion I guess. And no, I am not affiliated with them in anyway.
     
  14. mykemp macrumors newbie

    Joined:
    Dec 10, 2003
    Location:
    Richmond, VA
    #14
    Until your post, I hadn't heard of bookpool.com :)

    I'd be willing to give them a try though if they'll save me a buck or two.

    Myron
     
  15. jeremy.king macrumors 603

    jeremy.king

    Joined:
    Jul 23, 2002
    Location:
    Fuquay Varina, NC
    #15
    1-800-CALL-ATT will too ;)
     

Share This Page