in reply to Re^2: cgi and update event
in thread cgi and update event

Or, if you don't want to write the JavaScript yourself, you can use CGI::Ajax to handle the interfacing between the HTML/JavaScript page and your server-side Perl.