launch simple perl script from browser

K

kenny

hi folks,

i have a very basic question:

how can i launch my perl script in the browser via address bar?

I used a shell with the command "perl x.pl" and it worked. the paths
seem to be set all right.... thx in advance....


yours, kenny ajram
 
U

usenet

Bob said:
Well, one way would be to install a web server on your system. Modify
the Perl script to function as a CGI program.

A webserver is not necessary if you want to run the script on the same
machine that it resides on. You may "run" anything on the localhost
with the file://whatever syntax in the browser address bar.

Of course, it won't display output to the browser... but the program
WILL run.
 
M

Martijn Lievaart

A webserver is not necessary if you want to run the script on the same
machine that it resides on. You may "run" anything on the localhost
with the file://whatever syntax in the browser address bar.

Of course, it won't display output to the browser... but the program
WILL run.

No it won't.

+------------------------------------------------------------------+
| You have chosen to open |
| |
| test.pl |
| |
| which is a: Perl script |
| from: /home/martijn |
| |
| +- What should firefox do with this file? -------------------+ |
| | +---------------------------------------+ | |
| | (*) Open with |OpenOffice.org Writer (default) |x| | |
| | +---------------------------------------+ | |
| | ( ) Save to Disk | |
| | | |
| | [ ] Do this automatically for files like this from now on. | |
| +------------------------------------------------------------+ |
| [ X Cancel ] [ V OK ] |
+------------------------------------------------------------------+

M4
 
K

kenny

thanks for your help everybody! i used something like you suggested but
the browser shows me the source code of the .pl
how can i run it. i thought i would use a typically configured web
server??
 
K

kenny

thanks for your help everybody! i used something like you suggested but
the browser shows me the source code of the .pl
how can i run it? i thought i would use a typically configured web
server??
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,535
Members
45,008
Latest member
obedient dusk

Latest Threads

Top