If your CGI is in Perl and your local machine is Windows then install ActiveState Perl (www.activestate.com) on your local machine.
Then read the documentation on Perlscript which comes with ActiveState Perl.
Basically you will cut and past your entire Perl CGI script into the HTML page that you are serving up. You will place the CGI script inside <script language = "Perl"> ... </script>tags.
Finally attach the script to some button or other HTML object on the page, perhaps using the "action =" attribute on a form button. With some fiddling around your script will perform inside the client browser the same way that it would have on the server.