Author |
Message |
Mark Perr #1 / 36
|
 Perl on Windows 95
I am setting up a website and I want to use some scripts. I want to test them to make sure they work befor sending them to the ISP. I downloaded Perl for Windows 95/NT. I can see if a script compiles and what its output is in a dos box by typing C:\>perl myscript.pl. I would like to also see how it works by loading the page into Netscape locally and then running the script (like it would on a server). Is this possible. When I tried clicking on the button that calls the script nothing happened. Any suggestions? Thanks.
|
Fri, 06 Aug 1999 03:00:00 GMT |
|
 |
Hans Schrad #2 / 36
|
 Perl on Windows 95
You may want to check out our Perl for Windoze pages: URL="http://hjs.geol.uib.no/Perl/index3.htm" Quote: >I am setting up a website and I want to use some scripts. I want to >test them to make sure they work befor sending them to the ISP. I >downloaded Perl for Windows 95/NT. I can see if a script compiles and >what its output is in a dos box by typing C:\>perl myscript.pl. >I would like to also see how it works by loading the page into Netscape >locally and then running the script (like it would on a server). Is >this possible. When I tried clicking on the button that calls the >script nothing happened. >Any suggestions? >Thanks.
Hans Schrader-Eureka's SySop:
|
Sun, 08 Aug 1999 03:00:00 GMT |
|
 |
Hank LeMieu #3 / 36
|
 Perl on Windows 95
Mark, You wrote, Quote: > I would like to also see how it works by loading the page into Netscape > locally and then running the script (like it would on a server). Is > this possible. When I tried clicking on the button that calls the > script nothing happened.
Well, here are two options: 1)Use Netscape's File|Open command to directly open the script. When netscape says it doesn't know what to do with the file, tell it to open it with the script interpreter (ie: if you're using perl, tell it to use perl.exe as the helper.) All this will do is have Netscape open the perl command window and run the script every time you open a .pl file. This won't emulate what the script will do on the server. 2) Install a server on your machine and run it locally. That's how I test my scripts. Hank -- Hank LeMieux {*filter*} Web Design/JavaScript/CGI Santa Fe, NM, USA (505) 986-8166 http://www.*-*-*.com/
|
Sun, 08 Aug 1999 03:00:00 GMT |
|
 |
Hans Schrad #4 / 36
|
 Perl on Windows 95
You may want to check out our perl pages- URL=" http://www.*-*-*.com/ ; Quote: >Mark, >You wrote, >> I would like to also see how it works by loading the page into Netscape >> locally and then running the script (like it would on a server). Is >> this possible. When I tried clicking on the button that calls the >> script nothing happened. >Well, here are two options: >1)Use Netscape's File|Open command to directly open the script. When >netscape says it doesn't know what to do with the file, tell it to open >it with the script interpreter (ie: if you're using perl, tell it to use >perl.exe as the helper.) All this will do is have Netscape open the perl >command window and run the script every time you open a .pl file. This >won't emulate what the script will do on the server. >2) Install a server on your machine and run it locally. That's how I >test my scripts. >Hank >-- >Hank LeMieux >{*filter*} Web Design/JavaScript/CGI >Santa Fe, NM, USA >(505) 986-8166 > http://www.*-*-*.com/
Hans Schrader-Eureka's SySop:
|
Mon, 09 Aug 1999 03:00:00 GMT |
|
 |
Paul Del #5 / 36
|
 Perl on Windows 95
says... [snip...] Quote: >I would like to also see how it works by loading the page into Netscape >locally and then running the script (like it would on a server). Is >this possible. When I tried clicking on the button that calls the >script nothing happened.
I do this all the time on my machine. What you need is to run an HTTP server on your local Win95 machine. I use OmniHTTPd, a freeware server that supports SSI, standard cgi, and win-cgi. It's available from http://www.fas.harvard.edu/~glau/httpd/ I've been running it for a month or so, mostly with the win-cgi, but I have also run a few perl5 for win32 scripts through just for fun. You can easily find other free- and commercial-ware through the TUCOWS software archive: http://www.tucows.com/ HTH, Paul Delys
|
Tue, 10 Aug 1999 03:00:00 GMT |
|
 |
Bernie Cose #6 / 36
|
 Perl on Windows 95
Quote:
} I am setting up a website and I want to use some scripts. I want to } test them to make sure they work befor sending them to the ISP. I } downloaded Perl for Windows 95/NT. I can see if a script compiles and } what its output is in a dos box by typing C:\>perl myscript.pl. } } I would like to also see how it works by loading the page into Netscape } locally and then running the script (like it would on a server). Is } this possible. When I tried clicking on the button that calls the } script nothing happened.
Well, depending on how complicated your script is, I check that stuff the simple way: do "perl myscript.pl >myscript.html" and then just give Netscape the Location "C:\mydir\myscript.html" /Bernie\ -- Bernie Cosell Fantasy Farm Fibers
--> Too many people, too few sheep <--
|
Tue, 10 Aug 1999 03:00:00 GMT |
|
 |
Rasil #7 / 36
|
 Perl on Windows 95
On Mon, 17 Feb 1997 15:51:00 -0700, Mark Perry Quote:
>I am setting up a website and I want to use some scripts. I want to >test them to make sure they work befor sending them to the ISP. I >downloaded Perl for Windows 95/NT. I can see if a script compiles and >what its output is in a dos box by typing C:\>perl myscript.pl. >I would like to also see how it works by loading the page into Netscape >locally and then running the script (like it would on a server). Is >this possible. When I tried clicking on the button that calls the >script nothing happened. >Any suggestions? >Thanks.
I do exactly the same stuff. I downloaded/instaled Microsoft's Personal Web server and voila.... Now my partable acts just like the comercial web server that I am designing for. Whats more... this is free.
|
Tue, 10 Aug 1999 03:00:00 GMT |
|
 |
Hank LeMieu #8 / 36
|
 Perl on Windows 95
The subject is whether you can test your perl/CGI scripts by setting up a local server on Win95. Mostly you can, and I do. However, there is one key catch. I'm not familiar with the technicals, but apparently Win95 is unable to open a new port from your local server when your browser executes a CGI script that, for instance, sends email via BLAT. So, for example, I have a perl script that uses BLAT to email the results of a form submission. You can get this script to work from the command line, BLAT included. But if you go into your browser and access an HTML page on your local server, and that page calls the cgi script, BLAT will fail to open a port to send the mail. So keep this in mind. It will save you hours of debugfrustration. Hank -- Hank LeMieux {*filter*} Web Design/JavaScript/CGI Santa Fe, NM, USA (505) 986-8166 http://www.*-*-*.com/
|
Wed, 11 Aug 1999 03:00:00 GMT |
|
 |
Hans Schrad #9 / 36
|
 Perl on Windows 95
Follow the instructions on these perl page- I have exactly the same setup and all works just fine! URL="http://hjs.geol.uib.no/Perl/index3.htm" Quote:
>} I am setting up a website and I want to use some scripts. I want to >} test them to make sure they work befor sending them to the ISP. I >} downloaded Perl for Windows 95/NT. I can see if a script compiles and >} what its output is in a dos box by typing C:\>perl myscript.pl. >} >} I would like to also see how it works by loading the page into Netscape >} locally and then running the script (like it would on a server). Is >} this possible. When I tried clicking on the button that calls the >} script nothing happened. >Well, depending on how complicated your script is, I check that stuff the >simple way: do "perl myscript.pl >myscript.html" and then just give >Netscape the Location "C:\mydir\myscript.html" > /Bernie\ >-- >Bernie Cosell Fantasy Farm Fibers
> --> Too many people, too few sheep <--
Hans Schrader-Eureka's SySop:
|
Thu, 12 Aug 1999 03:00:00 GMT |
|
 |
Hans Schrad #10 / 36
|
 Perl on Windows 95
Maybe I misunderstood- BUT I can do this. You can have a look yourself at this URL=" http://www.*-*-*.com/ ; look for the BLAT_BLAH_BLAH entry! Quote: >The subject is whether you can test your perl/CGI scripts by setting up >a local server on Win95. >Mostly you can, and I do. However, there is one key catch. I'm not >familiar with the technicals, but apparently Win95 is unable to open a >new port from your local server when your browser executes a CGI script >that, for instance, sends email via BLAT. So, for example, I have a >perl script that uses BLAT to email the results of a form submission. >You can get this script to work from the command line, BLAT included. >But if you go into your browser and access an HTML page on your local >server, and that page calls the cgi script, BLAT will fail to open a >port to send the mail. >So keep this in mind. It will save you hours of debugfrustration. >Hank >-- >Hank LeMieux >{*filter*} Web Design/JavaScript/CGI >Santa Fe, NM, USA >(505) 986-8166 > http://www.*-*-*.com/
Hans Schrader-Eureka's SySop:
|
Thu, 12 Aug 1999 03:00:00 GMT |
|
 |
Christopher Rus #11 / 36
|
 Perl on Windows 95
Quote:
>>} I am setting up a website and I want to use some scripts. I want to >>} test them to make sure they work befor sending them to the ISP. I >>} downloaded Perl for Windows 95/NT. I can see if a script compiles and >>} what its output is in a dos box by typing C:\>perl myscript.pl.
If you're using CGI.pm (and if you're not, you should be) you can 1) specify the name/value pairs on th command line, or 2) read them in from a file. Then just pipe the output of the script to foo.html. If you're lazy, use open(STDOUT,"foo.html"); Chris Russo
|
Fri, 13 Aug 1999 03:00:00 GMT |
|
|