Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

execute cgi from file://

Posted on 1998-06-25
6
Medium Priority
?
181 Views
Last Modified: 2013-12-25
I need to be able to have perl CGI scripts executed from a local network rather than from the WWW. So the user would enter "file://..." on Unix or "file:C|\..." on Windows to start the path of the script rather than "http://..". The problem is that in Netscape, a window pops up that asks the user whether they want to save the file of type "application/x-perl". I want the user to be able to run that script so that they can have the interface of Netscape to run a script that will do something. And I don't want each user to have to modify their helper applications preferences. Of course, I also don't want the perl script to be displayed as plain text on the browser. I tried both text/plain as well as text/html as content types. Maybe I'm using them wrong???
0
Comment
Question by:Pakman
6 Comments
 
LVL 5

Expert Comment

by:julio011597
ID: 1829966
You need a web server to run CGI scripts, even locally.

-julio
0
 
LVL 2

Accepted Solution

by:
johnny99 earned 450 total points
ID: 1829967
Well, yes and no, you need the PERL program to run PERL scripts and you should be able to download a version of it for whatever platform you're on: but to have it return HTML to Netscape, yes, you need a web server.

However if you've got Windows NT servers, you should be able to set up a directory as an Intranet web server, and this is also possible with Mac servers of course.

Short answer: *can't* be done without a Web Server, *can* be done without the Internet.
0
 

Author Comment

by:Pakman
ID: 1829968
The script does exist on a web server. If I pull it up as http://somedomain/script.pl, it executes. But if I run it as file://path/script.pl it pops up the 'Unknown File Type' dialog box. It is on a Unix Apache web server.
0
Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 5

Expert Comment

by:julio011597
ID: 1829969
johnny the question-locker - among other interesting things - wrote:

> However if you've got Windows NT servers, you should be able to set up a
> directory as an Intranet web server

There are public domain web servers even for Win95.

While Packman revealed:

>  If I pull it up as http://somedomain/script.pl, it executes

So, why would you call it through "file:"? As said, CGI scripts need web servers, and web servers are also known as *http* servers...

-julio
0
 

Author Comment

by:Pakman
ID: 1829970
johnny99 said:
> Short answer: *can't* be done without a Web Server, *can* be done without the Internet.

Well, how can it be done without the Internet? It must not go out on the Internet.
0
 
LVL 85

Expert Comment

by:ozo
ID: 1829971
With a local web server on your machine.
0

Featured Post

[Webinar] Cloud and Mobile-First Strategy

Maybe you’ve fully adopted the cloud since the beginning. Or maybe you started with on-prem resources but are pursuing a “cloud and mobile first” strategy. Getting to that end state has its challenges. Discover how to build out a 100% cloud and mobile IT strategy in this webinar.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this tutorial I will focus on how to use WhizBase as a tool for sending ICQ messages to ICQ. Here I will use a new technology in WhizBase, published in WhizBase 5.1 version. In this tutorial I will use 3 files, pager.wbsp for the processing, e…
In threads here at EE, each comment has a unique Identifier (ID). It is easy to get the full path for an ID via the right-click context menu. However, we often want to post a short link within a thread rather than the full link. This article shows a…
Learn the basics of strings in Python: declaration, operations, indices, and slicing. Strings are declared with quotations; for example: s = "string": Strings are immutable.: Strings may be concatenated or multiplied using the addition and multiplic…
Learn the basics of modules and packages in Python. Every Python file is a module, ending in the suffix: .py: Modules are a collection of functions and variables.: Packages are a collection of modules.: Module functions and variables are accessed us…
Suggested Courses

782 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question