For Programmers: Free Programming Magazines  


Home > Archive > PERL Beginners > February 2006 > how to run perl file from a html page









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author how to run perl file from a html page
A B

2006-02-08, 9:06 am

Hello all,

i am new and want to get the params from html page and execute perl script
at local machine
please help me in this matter.

thanks and regards,

abhishek

Jeff Pang

2006-02-08, 9:06 am

I think this is a typical CGI-developing requirement.As someone in the list has said,

You could have a glance at chapter 12 of Beginning Perl for instance:
http://learn.perl.org/library/begin...3145_Chap12.pdf

Hope that be useful to you.

-----Original Message-----
>From: a b <testabhi@gmail.com>
>Sent: Feb 3, 2006 5:31 AM
>To: beginners@perl.org
>Subject: how to run perl file from a html page
>
>Hello all,
>
>i am new and want to get the params from html page and execute perl script
>at local machine
>please help me in this matter.
>
>thanks and regards,
>
>abhishek



--
Jeff Pang
NetEase AntiSpam Team
http://corp.netease.com
Xavier Noria

2006-02-08, 9:06 am

On Feb 3, 2006, at 11:31, a b wrote:

> Hello all,
>
> i am new and want to get the params from html page and execute perl
> script
> at local machine
> please help me in this matter.


How are you getting the HTML page in the local machine?

A B

2006-02-08, 9:06 am

Hy ,

my scenario is have a html page in your c:\statichtmlpage.html
in the section of form i've written like
< form method=post action=perfile.pl>
----
<>

and a perl file that can retrieve params from statichtmlpage.html file and
execute some thing at local machine

i don't want to install any web server :-)

Expecting your valuable suggestions and some sample.

Thanks
Abhishek
On 2/3/06, Jeff Pang <pangj@earthlink.net> wrote:
>
> I think this is a typical CGI-developing requirement.As someone in the
> list has said,
>
> You could have a glance at chapter 12 of Beginning Perl for instance:
> http://learn.perl.org/library/begin...3145_Chap12.pdf
>
> Hope that be useful to you.
>
> -----Original Message-----
> script
>
>
> --
> Jeff Pang
> NetEase AntiSpam Team
> http://corp.netease.com
>


Xavier Noria

2006-02-08, 9:06 am


On Feb 3, 2006, at 14:28, a b wrote:

> Hy ,
>
> my scenario is have a html page in your c:\statichtmlpage.html
> in the section of form i've written like
> < form method=post action=perfile.pl>
> ----
> <>
>
> and a perl file that can retrieve params from statichtmlpage.html
> file and
> execute some thing at local machine
>
> i don't want to install any web server :-)


Just to double-check, do you realise that from a static HTML file on
the disk you can only read the params as written in the source, and
there's no interaction with anybody with any web browser? No dynamic
content to read?

If you do, then the answer is to look at some HTML parser like
HTML::Parser or HTML::TreeBuilder and extract whatever you need.
Otherwise please reply sketching the flow of execution you have in mind.


JupiterHost.Net

2006-02-08, 9:06 am

a b wrote:
> Hy ,


Hello,

> my scenario is have a html page in your c:\statichtmlpage.html
> in the section of form i've written like
> < form method=post action=perfile.pl>
> ----
> <>
>
> and a perl file that can retrieve params from statichtmlpage.html file and
> execute some thing at local machine
>
> i don't want to install any web server :-)


So you want a plain text file to do an HTTP session with a local script?

*something* has to send the form's params to the script, i not a web
server then I suppose you could write javascript that will get executed
when they click submit that will take the form's values and run a system
commend to your script with those params, but its going to be very
difficult to server a dynamic web page with a web server to do it :)
A B

2006-02-08, 9:06 am

Hy all,

I think i got the solution i am using perlscript @ client side in that
webpage and i am able to got the params from user
and able to execute some functions (with out any web server)

Thanks for your help.
a b

On 2/3/06, JupiterHost.Net <mlists@jupiterhost.net> wrote:
>
> a b wrote:
>
> Hello,
>
> and
>
> So you want a plain text file to do an HTTP session with a local script?
>
> *something* has to send the form's params to the script, i not a web
> server then I suppose you could write javascript that will get executed
> when they click submit that will take the form's values and run a system
> commend to your script with those params, but its going to be very
> difficult to server a dynamic web page with a web server to do it :)
>
> --
> To unsubscribe, e-mail: beginners-unsubscribe@perl.org
> For additional commands, e-mail: beginners-help@perl.org
> <http://learn.perl.org/> <http://learn.perl.org/first-response >
>
>
>


Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com