MySQL Forums
Forum List  »  Perl

Re: Call Perl function in ....
Posted by: Bill Karwin
Date: June 16, 2006 05:06PM

onchange is a Javascript event, handled in the browser.
Perl is a server-side scripting language.
You cannot call a Perl function in the way you show above.
The content in the onchange='...' handler must be Javascript.

Here are a couple of options that are close to what you're describing:

1. You could use Ajax to make Javascript send a request to a Perl script on the server.

2. You could have a server-side parser scan the HTML page for syntax like the above and evaluate it as a Perl expression, substitute the result from the expression into the HTML, and then return that to the browser.

Regards,
Bill K.

Options: ReplyQuote


Subject
Written By
Posted
Re: Call Perl function in ....
June 16, 2006 05:06PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.