|
crosscreek -> frontpage and mysql coding question (2/28/2008 11:05:33)
|
I need a suggestion of help with coding. I am using frontpage 2003 & mysql database. I am learning ASP coding & am quickly learning that there's many ways to do things. I am trying to set up a simple Detail page where someone can see details in a mysql table. I am pretty certain that I am missing a code that will select the table, but anyway I type it I can't seem to get it to work. Below is my base code The connection works fine, but keep getting a option explicit error. there are many fields in the tbldog, but I am trying to show 1 field (name) at the moment. Just for simplicity sake. I've tried adding Dim MySQL the used MySQL = "SELECT * FROM tbldog" Still no luck. What am I missing? <%@ Language=VBScript %> <% Option Explicit %> <!-- #include virtual="/adovbs.inc" --> <!-- #include file="openconn.inc" --> <% Dim objRS Set objRS = Server.CreateObject("ADODB.Recordset") objRS.Open "tbldog", myConn, , , adCmdTable Do White Not objRS.EOF Response.Write "name: " & objRS("name") objRS.MoveNext Loop objRS.Close Set objRS = Nothing myConn.Close Set myConn = Nothing %>
|
|
|
|