N342 FAQ |
Modified: |
Currently, the following Windows setup gives to access your IUS Web site from home or wireless connection. The process is basically the same for XP or Vista. At IUS the Web site is the W: drive.
- Create a Virtual Private Network (VPN) connection from your computer to IUS.
- Open Network Connections (XP) or Control Panel | Network and Sharing Center (Vista).
- Click create New Network Connection
- Select Connect to Workplace
- Use Internet address of: vpn.ius.edu
- Enter your IU username and password.
- Map IUS Web site to your computer's W: drive.
- Open any folder.
- Open Tools.
- Select Map Network Drive.
Drive: W
Folder: \\se-cser-nas1\homepages\ads\usernamewhere username is your IU username.
The following error may occur when accessing XML files downloaded from one computer to another such as the ZIP files for the assignment. Vista (and perhaps XP) blocks access to files, presumably attempting to protect you from using files you have copied to your computer.Unblock access to individual files by the following:
- Open in Windows Explorer the directory containing the file, either the XML file or one referenced by the XML.
- Right click on the file and open Properties.
- Click Unblock.
The XML page cannot be displayed
Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later.
Access is denied. Error processing resource 'file:///W:/N341/Project/TraderSummaryContent.htm'.
Unblock access to all files in a directory by the following:
- Download Streams, copy Streams.exe to Windows directory if possible.
- To unblock all the files in directory c:\temp and any subdirectories enter:
Streams –d –s c:\temp
Host contacted, waiting for reply - Sometimes the IIS appears to hang, particularly after running ASP scripts or CGI programs. Stopping the transfer on the client will stop the client from waiting but the server may not repond to new requests. According to Microsoft documentation, the server cache fills and it takes a while (sometimes forever) to reclaim cache memory and continue. There are three solutions 1) let the browser wait for a while, perhaps 2 to 20 minutes, 2) reboot, always reliable, or 3) using the Global.Asa file, set the Server.ScriptTimeout = 10; and Session.Timeout = 1. We should be thankful the usual 'reinstall the operating system' solution isn't required.Why does the browser try to save the CGI file instead of executing? - The most common problem is due to sending invalid HTTP headers. The header must have:<Script LANGUAGE = VBScript RUNAT = Server>will limit the time the server spends trying to process a script. This can also be set inside of an ASP, the Server.ScriptTimeout is in seconds and is the maximum time the server will spend processing a script; Session.Timeout is in minutes and is the maximum time the server maintains session information. Its hard to tell if this really prevents the server from hanging, it seems to help and it is needed for timing out client sessions anyway.
Sub Session_OnStart
Server.ScriptTimeout = 10 ' Stop server processing after 10 seconds
Session.Timeout = 1 ' End session after 1 minute
End Sub
</Script>Testing CGI's - The server seems especially sensitive to CGIs that run amuck. It is generally possible to test Perl and C++ CGI behavior outside the server by defining environment variables. For Windows OS, the necessary environment variables, such as REQUEST_METHOD can be defined at the DOS prompt by:
set CONTENT_LENGTH = "15"then in Perl accessed for testing by the same means used when run as a CGI by the server:$size_of_form = $ENV{'CONTENT_LENGTH'};Virtual directories - The default location for server scripts/pages is c:\InetPub\wwwroot. To use other directories one must define a virtual directory. Right click on the file folder to make virtual and select Web Sharing. You should put the Global.Asa file in the root of the virtual drive to have it processed for ASP scripts.Global.Asa - An apparent problem requires that the server machine be rebooted for changes to the file to take effect.
.
Perl - Perl can be used as CGI programming language with PWS. Assuming that ActivePerl has been installed on directory c:\Perl then define the directory c:\Perl\bin as a virtual drive named Perl. The Perl interpreter can then be executed with the program path as an argument. Perl program named test.pl located on directory D:\N342 can then be executed by:localhost/Perl/perl.exe?D:/N342/test.plC++ - C++ or any other executeable file can be a CGI program. Assuming that a directory D:\CGI has been defined as a virtual drive named CGI. Any exe file placed in the directory can then be executed. A program named test.exe located on directory D:\CGI can then be executed by:localhost/CGI/test.exe
Content-type: text/html
before any HTML. Sending a cookie must be done before the Content-type.