⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 friendsitereg.asp

📁 一个功能很全面的设计网站,可以作为工作室、个人主页、技术网站等
💻 ASP
📖 第 1 页 / 共 2 页
字号:
<!--#include file="inc/conn.asp"-->
<!--#include file="inc/config.asp"-->
<!--#include file="inc/function.asp"-->
<!--#include file="inc/md5.asp"-->
<!--#include file="inc/ubbcode.asp"-->

<%
'=================================================
'过程名:ShowRootClass
'作  用:显示一级栏目(无特殊效果)
'参  数:无
'=================================================
sub ShowRootClass()
	dim sqlRoot,rsRoot
	sqlRoot="select C.ClassID,C.ClassName,C.RootID,L.LayoutFileName,C.LinkUrl From ArticleClass C"
	sqlRoot= sqlRoot & " inner join Layout L on C.LayoutID=L.LayoutID where C.ParentID=0 order by C.RootID"
	Set rsRoot= Server.CreateObject("ADODB.Recordset")
	rsRoot.open sqlRoot,conn,1,1
	if rsRoot.bof and rsRoot.eof then 
		response.Write("还没有任何栏目,请首先添加栏目。")
	else
		if ClassID>0 then
			response.write "&nbsp;&nbsp;&nbsp;&nbsp;<font color=f2f2f2>|</font>&nbsp;&nbsp;&nbsp;<a href='" & ChannelUrl & "'><font color=f2f2f2>&nbsp;&nbsp;易天首页&nbsp;</font></a>&nbsp;&nbsp;&nbsp;&nbsp;<font color=f2f2f2>|</font>"
		else
			response.write "&nbsp;&nbsp;&nbsp;&nbsp;<font color=f2f2f2>|</font>&nbsp;&nbsp;&nbsp;<a href='" & ChannelUrl & "'><font color=f2f2f2>&nbsp;&nbsp;易天首页&nbsp;</font></a>&nbsp;&nbsp;&nbsp;&nbsp;<font color=f2f2f2>|</font>"
		end if
		do while not rsRoot.eof
			if rsRoot(4)<>"" then
				response.write "<a href='" & rsRoot(4) & "' target='_blank'>&nbsp;&nbsp;&nbsp;<font color=f2f2f2>&nbsp;" & rsRoot(1) & "</font>&nbsp;</a>&nbsp;&nbsp;&nbsp;&nbsp;<font color=f2f2f2>|</font>"
			else
				if rsRoot(2)=RootID then
					response.Write "<a href='" & rsRoot(3) & "?ClassID=" & rsRoot(0) & "'>&nbsp;&nbsp;&nbsp;<font color=f2f2f2>&nbsp;" & rsRoot(1) & "</font>&nbsp;</a>&nbsp;&nbsp;&nbsp;&nbsp;<font color=f2f2f2>|</font>"
				else
					response.Write "<a href='" & rsRoot(3) & "?ClassID=" & rsRoot(0) & "'>&nbsp;&nbsp;&nbsp;<font color=f2f2f2>&nbsp;" & rsRoot(1) & "</font>&nbsp;</a>&nbsp;&nbsp;&nbsp;&nbsp;<font color=f2f2f2>|</font>"
				end if
			end if
			rsRoot.movenext
		loop
	end if
	rsRoot.close
	set rsRoot=nothing
	if ShowMyStyle="Yes" then
		response.write "<a href='#' onMouseOver='ShowMenu(menu_skin,100)'>&nbsp;自选风格&nbsp;</a>"
	end if
end sub

dim Action,FoundErr,ErrMsg
Action=trim(request("Action"))
if EnableLinkReg="No" then
	FoundErr=True
	ErrMsg=ErrMsg & "<br><li>管理员没有开放友情链接申请!</li>"
	call WriteErrMsg()
else
	if Action="Reg" then
		dim LinkType,LinkSiteName,LinkSiteUrl,LinkLogoUrl,LinkSiteAdmin,LinkEmail,LinkSitePassword,LinkSitePwdConfirm,LinkSiteIntro
		LinkType=trim(request("LinkType"))
		LinkSiteName=trim(request("SiteName"))
		LinkSiteUrl=trim(request("SiteUrl"))
		LinkLogoUrl=trim(request("LogoUrl"))
		LinkSiteAdmin=trim(request("SiteAdmin"))
		LinkEmail=trim(request("Email"))
		LinkSitePassword=trim(request("SitePassword"))
		LinkSitePwdConfirm=trim(request("SitePwdConfirm"))
		LInkSiteIntro=trim(request("SiteIntro"))
		if LinkType="" then
			FoundErr=True
			ErrMsg=ErrMsg & "<br><li>链接类型不能为空!</li>"
		else
			LinkType=Cint(LinkType)
			if LinkType=1 and (LinkLogoUrl="" or LinkLogoUrl="http://") then
				FoundErr=True
				ErrMsg=ErrMsg & "<br><li>请输入网站LOGO地址!</li>"
			end if
		end if
		if LinkSiteName="" then
			FoundErr=True
			ErrMsg=ErrMsg & "<br><li>网站名称不能为空!</li>"
		end if
		if LinkSiteUrl="" then
			FoundErr=True
			ErrMsg=ErrMsg & "<br><li>网站地址不能为空!</li>"
		end if
		if LinkSiteAdmin="" then
			FoundErr=True
			ErrMsg=ErrMsg & "<br><li>站长姓名不能为空!</li>"
		end if
		if LinkEmail="" then
			FoundErr=True
			ErrMsg=ErrMsg & "<br><li>Email不能为空!</li>"
		else
			if IsValidEmail(LinkEmail)=false then
				errmsg=errmsg & "<br><li>Email地址错误!</li>"
		   		founderr=true
			end if
		end if
		if LinkSitePassword="" then
			FoundErr=True
			ErrMsg=ErrMsg & "<br><li>网站密码不能为空!</li>"
		end if
		if LinkSitePwdConfirm="" then
			FoundErr=True
			ErrMsg=ErrMsg & "<br><li>确认密码不能为空!</li>"
		end if
		if LinkSitePwdConfirm<>LinkSitePassword then
			FoundErr=True
			ErrMsg=ErrMsg & "<br><li>网站密码与确认密码不一致!</li>"
		end if
		if LinkSiteIntro="" then
			FoundErr=True
			ErrMsg=ErrMsg & "<br><li>网站简介不能为空!</li>"
		end if
		if FoundErr<>True then
			dim sqlLink,rsLink
			sqlLink="select top 1 * from FriendSite where SiteName='" & dvHtmlEncode(LinkSiteName) & "' and SiteUrl='" & dvHtmlEncode(LinkSiteUrl) & "'"
			set rsLink=Server.CreateObject("Adodb.RecordSet")
			rsLink.open sqlLink,conn,1,3
			if not (rsLink.bof and rsLink.eof) then
				FoundErr=True
				ErrMsg=ErrMsg & "<br><li>你申请的网站已经存在!请不要重复申请!</li>"
			else
				rsLink.Addnew
				rsLink("LinkType")=LinkType
				rsLink("SiteName")=dvHtmlEncode(LinkSiteName)
				rsLink("SiteUrl")=dvHtmlEncode(LinkSiteUrl)
				rsLink("LogoUrl")=dvHtmlEncode(LinkLogoUrl)
				rsLink("SiteAdmin")=dvHtmlEncode(LinkSiteAdmin)
				rsLink("Email")=dvHtmlEncode(LinkEmail)
				rsLink("SitePassword")=md5(LinkSitePassword)
				rsLink("SiteIntro")=dvHtmlEncode(LinkSiteIntro)
				rsLink.update
				rsLink.close
				set rsLink=nothing
				call WriteSuccessMsg()
			end if
		end if
		if FoundErr=True then
			call WriteErrMsg()
		end if
	else
%>
<html>
<head>
<STYLE>
BODY
{scrollbar-face-color:E6E6D9; scrollbar-shadow-color:ffffff; 
scrollbar-highlight-color:bfbf9f; scrollbar-3dlight-color:ffffff; 
scrollbar-darkshadow-color:E6E6D9; scrollbar-track-color:f2f2f2; 
scrollbar-arrow-color:ffffff;}
</STYLE>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>申请友情链接</title>
<link href="img/index.CSS" rel="stylesheet" type="text/css">
<title>申请友情链接</title>
<script LANGUAGE="javascript">
<!--
function Check() {
if (document.AddLink.SiteName.value=="")
	{
	  alert("请输入网站名称!")
	  document.AddLink.SiteName.focus()
	  return false
	 }
if (document.AddLink.SiteUrl.value=="")
	{
	  alert("请输入网站地址!")
	  document.AddLink.SiteUrl.focus()
	  return false
	 }
if (document.AddLink.SiteUrl.value=="http://")
	{
	  alert("请输入网站地址!")
	  document.AddLink.SiteUrl.focus()
	  return false
	 }
if (document.AddLink.SiteAdmin.value=="")
	{
	  alert("请输入站长姓名!")
	  document.AddLink.SiteAdmin.focus()
	  return false
	 }
if (document.AddLink.Email.value=="")
	{
	  alert("请输入电子邮件地址!")
	  document.AddLink.Email.focus()
	  return false
	 }
if (document.AddLink.Email.value=="@")
	{
	  alert("请输入电子邮件地址!")
	  document.AddLink.Email.focus()
	  return false
	 }
if (document.AddLink.SitePassword.value=="")
	{
	  alert("请输入网站密码!")
	  document.AddLink.SitePassword.focus()
	  return false
	 }
if (document.AddLink.SitePwdConfirm.value=="")
	{
	  alert("请输入确认密码!")
	  document.AddLink.SitePwdConfirm.focus()
	  return false
	 }
if (document.AddLink.SitePwdConfirm.value!=document.AddLink.SitePassword.value)
	{
	  alert("网站密码与确认密码不一致!")
	  document.AddLink.SitePwdConfirm.focus()
	  document.AddLink.SitePwdConfirm.select()
	  return false
	 }
if (document.AddLink.SiteIntro.value=="")
	{
	  alert("请输入网站简介!")
	  document.AddLink.SiteIntro.focus()
	  return false
	 }
}

//-->
</script>
</head>

<body bgcolor="#4D4D4D">
<table width="760" height="95" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
  <!--DWLayoutTable-->
  <tr> 
    <td width="5" height="5"></td>
    <td width="750"></td>
    <td width="5"></td>
  </tr>
  <tr>
    <td height="85"></td>
    <td valign="top"><table  width="100%" border="0" cellpadding="0" cellspacing="0" bgcolor="f2f2f2" class="tde">
        <!--DWLayoutTable-->
        <tr> 
          <td width="750" height="85"><table width="100%" height="75" border="0" cellpadding="0" cellspacing="0">
              <tr> 
                <td width="27%" valign="bottom"> <div align="center"><img src="img/INDEX_r2_c2.gif" width="182" height="68"></div></td>
                <td width="60%"><table width="468" height="60" border="0" cellpadding="0" cellspacing="0" background="img/banner.jpg">
                    <tr>
                      <td> <div align="right">
                          <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="410" height="60">
                            <param name="movie" value="img/star.swf">
                            <param name="quality" value="high">
                            <param name="wmode" value="transparent">
                            <embed src="img/star.swf" width="410" height="60" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" wmode="transparent"></embed></object>
                        </div></td>
                    </tr>
                  </table></td>
                <td width="10%" valign="middle"> 
                  <table width="90" height="60" border="0" align="center" cellpadding="0" cellspacing="0">
                    <tr> 
                      <td height="18"> <div align="center"><strong>&#8226;&nbsp;</strong>&nbsp;<font color="#666666"><span  onclick="var strHref=window.location.href;this.style.behavior='url(#default#homepage)';this.setHomePage('http://www.dadayu.com');"  style="CURSOR: hand">设&nbsp;为&nbsp;首&nbsp;页</span></font></div></td>
                    </tr>
                    <tr> 
                      <td height="18"> <div align="center"><strong>&#8226;</strong>&nbsp;<font color="#666666"> 
                          <script language="JavaScript">
function bookmarkit(){window.external.addFavorite('http://www.qt66.com','非常视觉')}
if (document.all)document.write('<a href="#" onClick="bookmarkit()"><font color="#666666">加&nbsp;入&nbsp;收&nbsp;藏</font></a>')
</script>
                          </font></div></td>
                    </tr>
                    <tr> 
                      <td height="18"> <div align="center"><strong>&#8226;&nbsp;</strong>&nbsp;<a href="mailto:www@dadayu.com">联&nbsp;系&nbsp;我&nbsp;们</a></div></td>
                    </tr>
                  </table></td>
              </tr>
            </table></td>
        </tr>
      </table></td>
    <td></td>
  </tr>
  <tr>
    <td height="5"></td>
    <td></td>
    <td></td>
  </tr>
</table>
<table width="760" height="15" align="center" cellspacing="0">
  <tr> 
    <td height="10"></td>
  </tr>
</table>
<table width="760" height="532" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
  <!--DWLayoutTable-->
  <tr> 
    <td height="4"></td>
    <td></td>
    <td></td>
  </tr>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -