Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

question about subroutines

Status
Not open for further replies.

TmlMatus

Technical User
Nov 24, 2007
12
CA
is there a way of running a subroutine that is only activated when i press a button on my website? ... a side note ... the webpage is not the same as the webpage that called the perl code.

 
I'm not sure I fully understand your question. The button will need to be a form that calls something, if that form calls a perl script sure. Or are you trying to share a subroutine between two different scripts?

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[noevil]
Travis - Those who say it cannot be done are usually interrupted by someone else doing it; Give the wrong symptoms, get the wrong solutions;
 
no i mean that my 'index.htm' calls the perl program ... right? is there a way that i can make a subroutine inside my perl that would only be activated once i pressed submit on a different sub of my webpage ... ex.'productinfo.htm' or would i have to create a new perl program for each form?
 
no worries ... foudn a different way to do what i wanted to do.
 
good.. cause it's very easy.. look up CGI module at cpan.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[noevil]
Travis - Those who say it cannot be done are usually interrupted by someone else doing it; Give the wrong symptoms, get the wrong solutions;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top