=
Replace(Request("Content"),Chr(13)&Chr(10),"<br>")
sql="insert
into
table
values("
&
Content
&
")"
set
rs=
rsopen
---------------------
也就是说放在你的数据库 *** 作语句之前
---------------------
也可以在输出的时候直接
ResponseWrite
"<pre>"
&
Rs("Content")
&
"</pre>"
这个叫预格式化标签,可以把包含在其中的内容按原格式输出A页面
<%
Dim objrs1,strsql1
strsql1="select from 表名 where id=76"
set objrs1=servercreateobject("ADODBRecordset")
objrs1open strsql1,objconn,1,2,1
responsewrite objrs1("liuyan")
%>
B页面
<%
Dim objrs1,strsql1
strsql1="select from 表名 where id=82"
set objrs1=servercreateobject("ADODBRecordset")
objrs1open strsql1,objconn,1,2,1
responsewrite objrs1("liuyan")
%>
连接数据库你会吧using (OleDbConnection con = new OleDbConnection())
{
conConnectionString = "Provider=MicrosoftJetOLEDB40; Data Source=DBmdb";
var cmd = new OleDbCommand();
cmdConnection = con;
conOpen();
cmdCommandText = "select from TestTable";
OleDbDataReader reader = cmdExecuteReader();
while (readerRead())
{
ConsoleWrite(reader[0]ToString());
ConsoleWrite(reader[1]ToString());
ConsoleWriteLine();
}
}
ConsoleReadKey();
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)