More choices, more fun! Get Opera 9, Free!

Executing a perlscript from a perlscript

You are viewing this site as a guest. Join our community to get your questions answered and share knowledge. Active members may advertise and ask for a website critique.

They have: 45 posts

Joined: Aug 2000

How can it be done?

They have: 568 posts

Joined: Nov 1999

Uou can use fork, or just put it in a sub routine.

They have: 45 posts

Joined: Aug 2000

Fork?

They have: 193 posts

Joined: Feb 2000

require "server/path/to/script.cgi";

Richard
richjb::425

They have: 88 posts

Joined: Mar 1999

Sometimes I call a script using the following
code - not sure it's what your looking for:

this basically checks whether there was any input
in the input boxes and if not sends it back to the
original page:

if(!param('inputbox1') || !param('inputbox2'))
{
url="http://yourscriptnamehere.pl";
print "Location: $url\nURI: $url\n\n";
exit();
}

works quite well for me - can't remember who showed
me it - but it might work for you.

Regards

Steve

Mark Hensler's picture

He has: 4,044 posts

Joined: Aug 2000

myriad,
that just 'forwards' the client's browser to the other page.

Laguna-
richjb has got it.

Anyone know if PERL supports 'include' like PHP?
It's a differnt (and I think better) way to include/require files.

Mark Hensler ["Max Albert"] [Email]
If there is no answer on Google, then there is no question.

They have: 193 posts

Joined: Feb 2000

PERL also has the "use" statement, which is usually used for the requiring of modules.

I don't think it has an "include" statement that acts the same way as the PHP one does. However, I don't see why you can't just do:

$any = "variables";
$that = "I need."
require "path/to/script.cgi";

'

Richard
richjb::428

richard@brevig.com

Everyone here has a website. It's just that not all are worth posting (Mine! Smiling).