[dba-SQLServer] OT - HTML & ASP Help Required

Haslett, Andrew andrew.haslett at ilc.gov.au
Thu May 6 23:10:50 CDT 2004


This means that IIS didn't recognise the asp extension and hence couldn't
parse the code contained within.  When this occurs, it just sends you the
whole file instead.

Why does this occur?  Either IIS isn't installed or running correctly, OR it
is running correctly but the asp ISAPI 'mapping' isn't configured.

Under properties of the website -> Home Directory tab -> Configuration
Button -> ensure that asp mapping is there, pointing to the asp.dll
(c:\windows\system32\asp.dll)

A reinstall of IIS on the server will usually fix this all up for you...

Cheers,
Andrew

-----Original Message-----
From: paul.hartland at fsmail.net [mailto:paul.hartland at fsmail.net] 
Sent: Thursday, 6 May 2004 5:43 PM
To: dba-sqlserver
Subject: [dba-SQLServer] OT - HTML & ASP Help Required

To all,
 
Being a complete novice to HTML & ASP I bought myself a couple of books on
the subjects and have been playing around with a test logon page for our
company.  I have the HTML code (as below) saved as default.htm on a Windows
2000 server with IIS installed in the C:\Inetpub\wwwroot directory along
with the ASP code which is saved as checklogin.asp in the same directory.
On my Windows 98 machine at home with Personal Web Server (PWS) installed it
runs fine, however when trying to run it on our server in the office it just
displays the ASP code when the checklogin.asl page is called, and if you try
it from a desktop it comes up with a you are about to download
checklogin.asp page.
 
Has anyone any ideas whats wrong, or can point me to a list on HTML and ASP
etc.
 
default.htm code below:
<HTML>
<HEAD>
<TITLE>Orridge Reporting Logon</TITLE>
</HEAD>
<BODY Background="Niceblue.jpg">
            <CENTER>
            <H1><I><FONT FACE="Century" COLOR="WHITE">Orridge & Co. Internet
Reporting System</FONT></I></H1>
            <H3><FONT FACE="Century" COLOR="WHITE"><I>Enter Username &
Password Below</I></FONT></H2>
            <HR WIDTH="100%">
            <FORM METHOD=Post ACTION="CheckLogin.asp">
            <FONT FACE="Courier New" COLOR="BLACK"><B>Username:</B></FONT>
<INPUT TYPE=Text NAME="Username" SIZE="30">
            <P>
            <FONT FACE="Courier New" COLOR="BLACK"><B>Password:</B></FONT>
<INPUT TYPE=Password NAME="Password" SIZE="30">
            <P>
            <INPUT TYPE=Reset NAME="Reset" VALUE="Reset"> <INPUT TYPE=Submit
NAME="Submit" VALUE="Submit">
            </FORM>
            <HR WIDTH="100%">
            </CENTER>
            </BODY>
</HTML>
 
 
checklogin.asp code is below:
<%@ LANGUAGE="VBSCRIPT" %>
<% Option Explicit %>
 
<!--#Include Virtual="/ADOVBS.INC"-->
<%
            Dim objConn
            Dim objRs
            Dim strSQL
            Set objConn = Server.CreateObject("ADODB.Connection")
            objConn.ConnectionString="DRIVER={Microsoft Access Driver
(*.mdb)}; " & _
 
"DBQ=\\Development\C$\InetPub\Wwwroot\Genesis.mdb"
            objConn.Open
            
            Set objRs = Server.CreateObject("ADODB.RecordSet")
            strSQL = "SELECT * FROM tblUsers WHERE Username = '" &
Request.Form("Username") & "'"
            objRs.Open strSQL, objConn
            
            If (objRs.EOF) Then
                        Response.Write "<A HREF='Default.HTM'>"
                        Response.Write "User Not Registered."
                        Response.Write "</A>"
                        Response.End
            Else
                        Response.Write "<A HREF='Default.HTM'>"
                        Response.Write "User Found."
                        Response.Write "</A>"
                        Response.End
            End If
            
            objRs.Close
            Set objRs = Nothing
            objConn.Close
            Set objConn = Nothing
%>
 
Thanks in advance for any help.
 
Paul Hartland

-- 

Whatever you Wanadoo:
http://www.wanadoo.co.uk/time/

This email has been checked for most known viruses - find out more at:
http://www.wanadoo.co.uk/help/id/7098.htm
_______________________________________________
dba-SQLServer mailing list
dba-SQLServer at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/dba-sqlserver
http://www.databaseadvisors.com

IMPORTANT - PLEASE READ ******************** 
This email and any files transmitted with it are confidential and may 
contain information protected by law from disclosure. 
If you have received this message in error, please notify the sender 
immediately and delete this email from your system. 
No warranty is given that this email or files, if attached to this 
email, are free from computer viruses or other defects. They 
are provided on the basis the user assumes all responsibility for 
loss, damage or consequence resulting directly or indirectly from 
their use, whether caused by the negligence of the sender or not.



More information about the dba-SQLServer mailing list