PriNet has asked for the wisdom of the Perl Monks concerning the following question:

I have been messing with the code that i posted on my scratchpad, i know it's javascript, and i don't want to start anything (heh), but if someone could take a look, i been stumped for hours...
thanx
(oh yea, i DO primarily code in perl, theres just some cases...)
Thanx AnomalousMonk; prinet's scratchpad

I tried re-inventing the wheel again, but everytime I push it, it still falls flat on it's side...
  • Comment on (OT) javascript issue (undefined reference error)

Replies are listed 'Best First'.
Re: (OT) javascript issue (undefined reference error)
by AnomalousMonk (Archbishop) on Mar 19, 2016 at 23:01 UTC
Re: (OT) javascript issue (undefined reference error)
by Anonymous Monk on Mar 20, 2016 at 00:05 UTC
    What is it supposed to do?
      I suppose i should have mentioned what it's doing yes, sorry, i was just looking for the error. This particular function generates an input field in the calling div so it can be handeled appropiately in the perl script; ie; i can disect the value and perform another function on my page, or, (primarily), right now i dump it into a json file for the irc connection script. all i was trying to do was generate an alert that i got all the data i needed, but i ran into this error. it does, however "alert" all the proper data if i place a seperate alert outside "this" alert function, so, it's there, i just could not figure out why the "posted" value displayed properly, and the "username" value errors out. entry values are: string for the div id, a number (time()) for the posted, and another string that contains the username.again, you were right anonymous, i should have explained more, i was just fustrated looking for that error.

      I tried re-inventing the wheel again, but everytime I push it, it still falls flat on it's side...
        Ok, make a closure, no string eval stuff
        Var myckosure = function(){ if (event.keyCode == 13) { ... UserName ... } Return; }; CommandInput.setAttribute('ONKEYPRESS', myclosure );
      String eval is bad in javascript too