<% if request("action")="update_dir" then conn.execute("update SL_config set C_dir='"&split(Request.ServerVariables("PATH_INFO"),"index.asp")(0)&"'") call box("更新成功!","index.asp","success") end if if right(Request.ServerVariables("PATH_INFO"),9)="index.asp" and C_dir<>split(Request.ServerVariables("PATH_INFO"),"index.asp")(0) then response.Write "系统检测到您移动了安装目录,是否更新数据库?(/否)"&split(Request.ServerVariables("PATH_INFO"),"index.asp")(0) response.end() end if if request.QueryString("lang")="" and request.QueryString("type")="" then session("i")=C_delang end if if C_delang=0 then session("e")="" else session("e")="e" end if S_page=Server.URLEncode(request.QueryString("page")) if request.QueryString("type")="" then U_type="index" else U_type=Server.URLEncode(request.QueryString("type")) end if if request.QueryString("S_id")="" then S_id=1 else S_id=Server.URLEncode(request.QueryString("S_id")) end if if C_close=1 then response.Redirect("close.html") end if if C_todomain<>"empty" and C_todomain<>"" and C_todomain<>C_domain then response.Redirect "http://"&C_todomain end if if C_first=1 then response.Redirect("install.asp") end if if request.QueryString("M_id")<>"" and request.QueryString("auth")<>"" then call auth(request.servervariables("HTTP_HOST")&"|"&request.QueryString("M_id")&"|"& request.QueryString("auth")) end if If WAPstr()=true and W_show=2 Then response.redirect "wap_index.asp?type="&U_type&"&S_id="&S_id response.end() End if if C_html=1 and U_type<>"index" then select case U_type case "text" response.Redirect "html/text/"&S_id&".html" case "news" response.Redirect "html/news/list-"&S_id&".html" case "newsinfo" response.Redirect "html/news/"&S_id&".html" case "product" response.Redirect "html/product/list-"&S_id&".html" case "productinfo" response.Redirect "html/product/"&S_id&".html" case "form" response.Redirect "html/form/"&S_id&".html" case "contact" response.Redirect "html/contact/index.html" case "guestbook" response.Redirect "html/guestbook/index.html" end select end if select case U_type case "index" Response.Write ReplaceLableFlag(ReplaceTag(CreateHTMLReplace(ReplacePart(CreateIndex(LoadTemplate("index",1)))))) case "contact" Response.Write ReplaceLableFlag(ReplaceTag(CreateHTMLReplace(ReplacePart(CreateContact(LoadTemplate("contact",1)))))) case "guestbook" Response.Write ReplaceLableFlag(ReplaceTag(CreateHTMLReplace(ReplacePart(CreateGuestbook(LoadTemplate("guestbook",1)))))) case "text" Response.Write ReplaceLableFlag(ReplaceTag(CreateHTMLReplace(ReplacePart(CreateText(LoadTemplate("text",S_id),S_id))))) case "form" Response.Write ReplaceLableFlag(ReplaceTag(CreateHTMLReplace(ReplacePart(CreateForm(LoadTemplate("form",S_id),S_id))))) case "news" Response.Write ReplaceLableFlag(ReplaceTag(CreateHTMLReplace(ReplacePart(CreateNewsList(LoadTemplate("news",S_id),S_id,S_page))))) case "newsinfo" Response.Write ReplaceLableFlag(ReplaceTag(CreateHTMLReplace(ReplacePart(CreateNewsInfo(LoadTemplate("newsinfo",S_id),S_id))))) case "product" Response.Write ReplaceLableFlag(ReplaceTag(CreateHTMLReplace(ReplacePart(CreateProductList(LoadTemplate("product",S_id),S_id,S_page))))) case "productinfo" Response.Write ReplaceLableFlag(ReplaceTag(CreateHTMLReplace(ReplacePart(CreateProductInfo(LoadTemplate("productinfo",S_id),S_id))))) case else Response.Write ReplaceLableFlag(ReplaceTag(CreateHTMLReplace(ReplacePart(LoadTemplate("index",1))))) end select %>