Javascript syntax

Discussion in 'Javascript' started by andresjv@gmail.com, Aug 24, 2007.

  1. Guest

    Hello there! I'm an old school javascript programmer, and recently
    found this code:

    # AIM = {
    #
    # frame : function(c) {
    #
    # var n = 'f' + Math.floor(Math.random() * 99999);
    # var d = document.createElement('DIV');
    # d.innerHTML = '<iframe style="display:none"
    src="about:blank" id="'+n+'" name="'+n+'" onload="AIM.loaded(\''+n
    +'\')"></iframe>';
    # document.body.appendChild(d);
    #
    # var i = document.getElementById(n);
    # if (c && typeof(c.onComplete) == 'function') {
    # i.onComplete = c.onComplete;
    # }
    #
    # return n;
    # },
    #
    # form : function(f, name) {
    # f.setAttribute('target', name);
    # },
    #
    # submit : function(f, c) {
    # AIM.form(f, AIM.frame(c));
    # if (c && typeof(c.onStart) == 'function') {
    # return c.onStart();
    # } else {
    # return true;
    # }
    # } ... more code

    Could someone please tell me what is AIM? a class? a what? also, what
    are frame, form and submit? are they events or something like that?

    Could you please also tell me where I can learn this syntax?

    thanks a lot...
     
    , Aug 24, 2007
    #1
    1. Advertisements

  2. wrote:
    > # AIM = {
    > #
    > # frame : function(c) {
    > # [...]
    > # }
    >
    > Could someone please tell me what is AIM?


    Sure.

    > a class?


    There are no classes in *client-side* ECMAScript implementations yet.

    > a what?


    A reference to an (Object) object.

    > also, what are frame, form and submit?


    Methods of that object, i.e. function-type properties.

    > are they events or something like that?


    No.

    > Could you please also tell me where I can learn this syntax?


    http://jibbering.com/faq/ pp.


    PointedEars
    --
    realism: HTML 4.01 Strict
    evangelism: XHTML 1.0 Strict
    madness: XHTML 1.1 as application/xhtml+xml
    -- Bjoern Hoehrmann
     
    Thomas 'PointedEars' Lahn, Aug 24, 2007
    #2
    1. Advertisements

  3. Guest

    Wow!!! that was quick! thanks for the information!
     
    , Aug 24, 2007
    #3
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Jim Baker

    Javascript integration/syntax

    Jim Baker, Oct 16, 2003, in forum: ASP .Net
    Replies:
    0
    Views:
    390
    Jim Baker
    Oct 16, 2003
  2. Dale

    Javascript / C# variable syntax

    Dale, Oct 12, 2004, in forum: ASP .Net
    Replies:
    2
    Views:
    10,926
  3. Eitan
    Replies:
    2
    Views:
    650
    Eitan
    Jun 4, 2005
  4. gabriele renzi
    Replies:
    2
    Views:
    372
    gabriele renzi
    Dec 31, 2005
  5. Ken Bloom
    Replies:
    3
    Views:
    463
  6. Good Night Moon
    Replies:
    9
    Views:
    535
    Rick DeNatale
    Jul 25, 2007
  7. Jacob Grover
    Replies:
    5
    Views:
    522
    Jacob Grover
    Jul 18, 2008
  8. Mark Richards
    Replies:
    3
    Views:
    494
    Tad McClellan
    Nov 18, 2007
Loading...