javascript error while using ASP.Net form

Discussion in 'ASP .Net Building Controls' started by Manoj Mathew, Aug 23, 2004.

  1. Manoj Mathew

    Manoj Mathew Guest

    I get a javascript error while loading an ASP.Net page. The page contains a
    form to which ASP.Net inserts a name which has ":" charachter. The
    javascript generated by ASP.Net gives an error of an Expected ";". The
    javascript code generated is

    function __doPostBack(eventTarget, eventArgument) {
    var theform;
    if (window.navigator.appName.toLowerCase().indexOf("netscape") > -1)
    {
    theform = document.forms["_ctl0:_ctl0:MediaPartnerForm136"];
    }
    else
    {
    theform = document._ctl0:_ctl0:MediaPartnerForm136;
    }
    theform.__EVENTTARGET.value = eventTarget.split("$").join(":");
    theform.__EVENTARGUMENT.value = eventArgument;
    theform.submit();
    }


    The form has the attributes

    <form name="_ctl0:_ctl0:MediaPartnerForm136" method="post"
    action="lightbox.aspx" id="_ctl0__ctl0_MediaPartnerForm136">

    Can someone give me some insight on this if this can be handled?


    Manoj
     
    Manoj Mathew, Aug 23, 2004
    #1
    1. Advertising

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. ^CrazyCoder^
    Replies:
    3
    Views:
    7,315
    Terrence Benade
    Sep 15, 2003
  2. David Virgil Hobbs
    Replies:
    0
    Views:
    537
    David Virgil Hobbs
    Jan 6, 2004
  3. Vinod I
    Replies:
    2
    Views:
    2,229
    Alvin Bruney [MVP]
    Mar 2, 2004
  4. amit
    Replies:
    2
    Views:
    488
  5. David
    Replies:
    1
    Views:
    517
    David
    Jul 19, 2004
Loading...

Share This Page