MySQL Forums
Forum List  »  Microsoft Access

Okay....
Posted by: Jim Rudnick
Date: July 29, 2004 05:21PM

Hello Nick..

Um...fine. Here's the entire code for the asp page that is supposed to record who enters the website. It's still under dev, so it's on my dev box...but I use IIS5 and w2kPro and have dev asp sites for 5 years or so by now...

Here's that page...
=========================================================
<%
nDate=date()
nTime=time()
'set var to the date and time functions built into asp

%>
<!--#Include file ="dbConn.asp"-->
<%
' get passed var to use for visitors name...

visitorName = Request.QueryString("Visitor")

' find out the visitors IP here...
comeFrom = Request.ServerVariables("REMOTE_ADDR")

' create the SQL query here....

SQL = "SELECT * FROM Visitors"

' connect to mySQL and get queried items...

rs.open SQL, conn, 2,3

' write new visitor to dbase to record this visit...

rs.AddNew

rs.Fields("Visitor") = visitorName

rs.Fields("VisitDate") = nDate & " " & nTime

rs.Fields("IP") = comeFrom

rs.Update

Response.Redirect("index.asp")
%>
============================================================

Heres' the source code for the table that is supposed to HOLD this visitors list...

CREATE TABLE `visitors` (
`Id` int(6) unsigned NOT NULL auto_increment,
`Visitor` varchar(15) NOT NULL default '',
`VisitDate` datetime NOT NULL default '0000-00-00 00:00:00',
`IP` varchar(20) NOT NULL default '',
PRIMARY KEY (`Id`)
) TYPE=MyISAM;

==========================================================
And a reminder, that when I use a 3 char name/password like Jim/tvr it works perfectly, and I can see the proper visitors listing showing that login.

It's when I try to use David/qqq that it fails with that damn error...and I've no idea why?

Jim

Options: ReplyQuote


Subject
Views
Written By
Posted
4523
July 29, 2004 02:46PM
2721
July 29, 2004 03:39PM
Okay....
2879
July 29, 2004 05:21PM
2537
July 30, 2004 12:40AM
2866
July 30, 2004 07:43AM
2539
July 30, 2004 08:11AM
2584
July 30, 2004 03:17PM
2560
July 31, 2004 02:06AM
2579
July 31, 2004 12:07PM
2648
August 01, 2004 09:12AM
2554
August 02, 2004 06:15PM
2562
August 03, 2004 01:49PM
2715
August 03, 2004 01:48PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.