单一的提示,数据库出错

来源:百度知道 编辑:UC知道 时间:2024/05/17 00:25:25
东西都传到站里去了,但是打开网页的时候显示 数据库连接出错!
就这么几个字!又没提示修改字串!请问是什么原因啊~
我的CONN文件发上来请大家帮我看下!
<%
on error resume next
DBPath="db/"
DB=DBPath&"database.mdb"
if err.number<>0 then
err.clear
set conn=nothing
response.write "数据库连接出错!"
Response.End
else
conn.open connstr
if err then
err.clear
set conn=nothing
response.write "数据库连接出错!"
Response.End
end if
end if
Response.Buffer=True
session.timeout=20
'on error resume next
Set fso = Server.CreateObject("Scripting.FileSystemObject")
if fso.FolderExists(server.MapPath("include"))=false then
DB="../"&DB
end if
set fso=nothing
sqlnow="now()"
connstr="provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Server.MapPath(DB)
Set conn = Server.CreateObject("ADODB.Connection")
%>

见意,你在本地机子上装上IIS来调试一下,有可能是别的文件错误,有可是
<!--#include file="buyok_shop_info.asp" -->
<!--#include file="buyok_functions.asp" -->
<!--#include file="settimeout.asp" -->
这里的文件连接错误。你试一下,IIS。如果出错,它会提示相应的多少行,有错误。