Go Back   PCMech Forums > Help & Discussion > Web Design / Development

Need Some Help? Type Your Keywords Here:

Reply
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
Old 09-26-2001, 04:35 PM   #1
Don't tread on me
 
cobra's Avatar
 
Join Date: Mar 1999
Location: Florida
Posts: 2,121
Send a message via ICQ to cobra Send a message via AIM to cobra
Lightbulb need html/cgi/access help QUICK!

ok, I need to make a simple web page with a form(a few input boxes)
customername
phonenumber

then what I need to do is when a person clicks on submit, I need this info to go into an access database. Would also like time and date stamp when entered also.
I can create a form no problem, but I have no practical exper. with posting the info into a db.
Help guys, I need this like right now.
__________________
Miami, flee it like a native.
cobra is offline   Reply With Quote
Old 09-29-2001, 04:55 AM   #2
SQL nutcase
 
mosquito's Avatar
 
Join Date: Sep 2000
Location: Belgium
Posts: 1,136
Send a message via AIM to mosquito
What webserver are you using? If you are using IIS on nt or 2K you can do this using an ASP page or with a perl scri. If you are doing this with a linux box and apache, then you can use perl or php.
mosquito is offline   Reply With Quote
Old 09-29-2001, 05:23 AM   #3
SQL nutcase
 
mosquito's Avatar
 
Join Date: Sep 2000
Location: Belgium
Posts: 1,136
Send a message via AIM to mosquito
An ASP example:
put the following code in a page insert.asp (or anything else) and put insert.asp in the action property of your form. Also make sure that there is a field "code" and a field "name" in the form.
Code:
<html>
<body>
	<h1>processing</h1>
	<%	Saveinfo 	%>
</body>
</html>

<%

sub SaveInfo()
	dim conn
	
	set conn = createobject("ADODB.connection")
	
	conn.open "driver={Microsoft Access Driver (*.mdb)};dbq=c:\inetpub\wwwroot\test\northwind.mdb;uid=Admin" 
	
	'note that code is an integer, and name a string
	conn.execute ("insert into t_table (id, name) values (" & request("code") & ", """ & request("name") & """)")
	response.redirect("otherpage.htm")

	conn.close
	set conn = nothing
end sub

%>
mosquito is offline   Reply With Quote
Reply

Bookmarks

Still Need Help? Type Your Keywords Here:


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -5. The time now is 07:29 AM.
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.
SEO by vBSEO 3.6.0 PL2