HOME | GETTING STARTED | WEB HOSTING | DOMAINS | MY ACCOUNT | SUPPORT | ABOUT
       Support: Manual: CGI: CGIWrap

Home: Support: Manual: CGI: CGIWrap:

Using CGIWrap

CGIWrap is a program that allows scripts to be run by the Web Server so that it has the permissions of the owner of the script. In other words, if the Web Server is running a script owned by you, it can assume your privileges and do such things as write to files and directories owned by you. You therefore do not need to create world-writable directories for such things as bulletin boards, guestbooks, etc.

Using CGIWrap is easy. In all of the below examples, replace SERVER with the hostname and port of your webserver. Replace USER with your userid, and replace SCRIPT with the pathname of the script that is located in the directory containing your web pages. (e.g., If you have the script count.cgi is your directory cgi-local, then SCRIPT=cgi-local/count.cgi.)

In the below URLs you can replace ""cgiwrap"" according to the following:

cgiwrap
Normal script execution
cgiwrapd
Executes script, but returns debugging information, also is returned preformatted, so you can see the source that the script is outputting.
nph-cgiwrap & nph-cgiwrapd
Same as above, except you sometimes need to use this if your script outputs binary data, such as an image counter script.
Standard Installation of CGIWrap
  • http://SERVER/cgi-bin/cgiwrap/USER/SCRIPT
  • http://SERVER/cgi-bin/cgiwrap?user=USER&script=SCRIPT
Notes

The syntax examples above using "user=" and "script=" are carryovers from the original versions of CGIwrap, and are not really needed. We highly recommend you don't use them, the other examples are much clearer and easier to use.

As an example, you can see CGIWrap being used when you are using your Control Panel. The URL shows CGIWrap being used on the secure server as "https://secure.atlas-host.com/cgi-bin/cgiwrap/root/controlcenter/ez1.cgi"


COPYRIGHT © 2001-2002 ATLAS-HOST.COM