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

This node falls below the community's threshold of quality. You may see it by logging in.
  • Comment on Calling internal subroutine from a form submit

Replies are listed 'Best First'.
Re: Calling internal subroutine from a form submit
by GhodMode (Pilgrim) on Feb 04, 2006 at 10:08 UTC

    I pretty much agree with ikegami, but I can imagine what you're looking for.

    Use a hidden input field to let your script know to process the form. Then you can check for the CGI parameter with your script. If it's there, execute your subroutine...

    use strict; use warnings; #... my $cgi = new CGI; if ( $cgi->param('runsub') ) { run_subroutine( $cgi ); }
    --
    -- GhodMode
    
    A reply falls below the community's threshold of quality. You may see it by logging in.
Re: Calling internal subroutine from a form submit
by ikegami (Patriarch) on Feb 04, 2006 at 08:17 UTC
    We can't find your problem if we can't see your work.