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

📄 add.asp

📁 个人网站系统,本人基于第三方源码进行更改!
💻 ASP
📖 第 1 页 / 共 2 页
字号:
<!--#include file="Common/Inc_DatConn.asp"-->
<!--#include file="Common/Inc_Config.asp"-->
<!--#include file="Common/Inc_Function.asp"-->
<!--#include file="ipcode.asp"-->
<%
'┌─  风云ASP在线  ────────────────────────┐
'│                                                                 │
'│  作者:赵振波.	http://www.fyasp.com	    				    │
'│                                                                 │
'│   Q Q:176189168  										   	    │
'│                                                                 │
'│ Email:fy96@163.com                                             │
'│                                                                 │
'│ 程序定做,系统开发,网站制作,提供高质量的网络产品、技术和服务!│
'│                                                                 │
'│【版权声明】                                                     │
'│                                                                 │
'│     本程序版权归坐看风云所有,未经授权擅自修改、复制或散布本程序│
'│                                                                 │
'│的部分或全部,将承受严厉的民事和刑事处罚,对已知的违反者将给予法 │
'│                                                                 │
'│律范围内的全面制裁。对非法使用此程序所造成的一切后果本人概不负责!│
'│                                                                 │
'└───────────────────  http://www.fyasp.com ──┘
%>
<html>
<head>
<title><% = strSiteName%>-免费发布信息</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta content="交友, 征友, 速配, 约会, 聊天, 征婚, 婚介, 爱情, 友情, 友谊, 朋友, 伙伴, 情人, 伴侣, 同性, 异性, 女人, 男士, 女士, 男孩, 女孩, 帅哥, 美女, 单身, 独身, 性感, 浪漫, 激情, 手机交友, 手机, 短信, 彩信, 铃声, 图片, 照片, 靓照, 贴图, 语音, 视频, 搜索, 文章, 商城" name="KEYWORDS">
<link href="Common/Style.css" type="text/css" rel="stylesheet">
<script language="javascript" src="fyfile/ResExplore.js"></script>
<script language="JavaScript">
//资源管理器所在的具体目录
ResourceExplorePath="fyfile/ResourceExplore.asp";
/*
参数说明:
自定义函数(返回的资源记录ID,资源名题,原始文件名称,最后更新时间) 
*/
function bbimg(Id,fTitle,fName,fDate)
{
	//请在下面添加你的代码
	myform.pic.value="fyfile/OpenFile01.asp?pID="+Id;
}
</script>
<!-- 结束 -->
<%
set rss=server.createobject("adodb.recordset")
sqls = "select * from SmallClass order by sj desc"
rss.open sqls,conn,1,1
%>
<script language = "JavaScript">
var onecount;
subcat = new Array();
        <%
        count = 0
        do while not rss.eof 
        %>
subcat[<%=count%>] = new Array("<%= trim(rss("id"))%>","<%=trim(rss("dl"))%>","<%= trim(rss("smallclassname"))%>");
        <%
        count = count + 1
        rss.movenext
        loop
        rss.close
        %>
onecount=<%=count%>;

function changelocation(locationid)
    {
    document.myform.SmallClassName.length = 1; 
    var locationid=locationid;
    var i;
    for (i=0;i < onecount; i++)
        {
            if (subcat[i][1] == locationid)
            { 
                document.myform.SmallClassName.options[document.myform.SmallClassName.length] = new Option(subcat[i][2], subcat[i][0]);
            }        
        }
    }    

</script>
<script language="javascript">
<!--
function IsDigit(){
  return ((event.keyCode >= 48) && (event.keyCode <= 57));
}
// -->
</script>
</head>

<body bgColor="#ffffff" leftMargin="0" topMargin="0" marginheight="0" marginwidth="0">
<!--#include file="Top.asp"-->
<script language="javascript">
//检查email的合法性
function checkemail(inputstr){
	if(inputstr.indexOf('@') != -1 && inputstr.indexOf('.')!= -1)
		return true;
	else 
   		return false;	
}
//检验表单的合法性
function addinfock(){
	if (document.myform.InfoAdd.value == "0") {
		alert("\请选择信息面向的地区!");
		document.myform.InfoAdd.focus();
		return false;
	}
    else if (document.myform.Topic.value == "") {
		alert("\请填写信息主题!");
		document.myform.Topic.focus();
		return false;
	}
	else if (document.myform.Content.value == "") {
		alert("\请填写信息内容!");
		document.myform.Content.focus();
		return false;
	}
	else if (document.myform.ContactMan.value == "") {
		alert("\请填写联系人!");
		document.myform.ContactMan.focus();
		return false;
	}
	else if (document.myform.Tel.value == "") {
		alert("\请填写联系电话!");
		document.myform.Tel.focus();
		return false;
	}
		else if (document.myform.Email.value == "") {
		alert("\请填写联系 E-Mail!");
		document.myform.Email.focus();
		return false;
	}
	else if (document.myform.Email.value == "" || !checkemail(document.myform.Email.value)) {
		alert("\E-Mail 填写错误,请填写有效的信箱,如 username@163.com !");
		document.myform.Email.focus();
		return false;
	}
	else if (document.myform.InfoDate.value == "0") {
		alert("\请选择信息有效期!");
		document.myform.InfoDate.focus();
		return false;
	}
}
</script>
<table align="center" border="0" width="760" cellspacing="0" cellpadding="0">
  <tr>
    <td width="100%">
      <p align="center"><img height="14" src="images/pic_top_01.gif" width="760" border="0"></td>
  </tr>
</table>
<div align="center">
<center>
<table id="AutoNumber8" style="BORDER-COLLAPSE: collapse" cellSpacing="0" cellPadding="0" width="760" border="0">
  <tbody>
  <tr>
    <td vAlign="top" width="1" background="images/space_01.gif"><img height="1" src="images/space_01.gif" width="1" border="0"></td>
    <td vAlign="top" width="10"><img height="1" src="images/space.gif" width="10" border="0"></td>
    <td vAlign="top" width="580">
      <div align="center">
      <center>
      <table id="AutoNumber12" style="BORDER-COLLAPSE: collapse" height="103" cellSpacing="0" cellPadding="0" width="580" border="0">
        <tbody>
        <tr>
          <td vAlign="top" height="3"></td>
        <tr>
          <td vAlign="top" height="100"><img src="images/ad_01.gif" width="580" height="100" alt="一号广告位"></td></tr></tbody></table></center></div>
      <div align="center">
      <center>
      <table id="AutoNumber11" style="BORDER-COLLAPSE: collapse" height="73" cellSpacing="0" cellPadding="0" width="580" border="0">
        <tbody>
        <tr>
          <td vAlign="center" background="images/bg_quick_search_01.gif" height="63" align="center"><!--#include file="Common/Inc_Search.asp"--></td>
        </tr>
        <tr>
          <td vAlign="top" height="10"></td></tr></tbody></table></center></div>
      <table border="0" width="100%" cellspacing="0" cellpadding="0" height="25">
        <tr>
          <td width="100%" height="30">&nbsp;您的位置:<a href="index.asp" class="links">首 页</a> -&gt;&gt; 发布信息</td>  
        </tr>
      </table>

      <table border="0" width="100%" cellspacing="0" cellpadding="0" background="images/002.gif" height="25">
        <tr>
          <td width="100%">
            <table border="0" width="102%" cellspacing="0" cellpadding="0" height="25">
              <tr>
                <td width="100%"><font color="#FFFFFF">
				&nbsp;&nbsp;注:<%if sh=1 then%>请发布真实信息,若信息合法,我们保证24小时内</font><font color="#FFFF00">审核</font><font color="#FFFFFF">后发布。</font><%else%><font color="#FFFFFF">好消息,为了方便大家交易,本站现在关闭信息审核!</font><%end if%></td>                  
              </tr>
            </table>
          </td>
        </tr>
      </table>
    </center>
      <div align="center">
            <table borderColor="#111111" cellSpacing="0" cellPadding="0" width="100%" bordercolordark="#FFFFFF" borderColorLight="#3986CE" border="1"><tbody>
              <tr>
                <td vAlign="top" width="100%" align="center">
                <table width="100%" height="22" border="0" cellpadding="0" cellspacing="0">
                  <tr> 
                    <td height="23" valign="top"> 
                      <table width="100%" height="20" border="0" cellpadding="4" cellspacing="1" bgcolor="#FFFFFF">
                        <tr> 
                          <td width="100%" valign="center" style="line-height: 150%">
                  <br>
<%
function GetIp()
	'如果客户端用了代理服务器,则应该用ServerVariables("HTTP_X_FORWARDED_FOR")方法
	getclientip = Request.ServerVariables("HTTP_X_FORWARDED_FOR")
	If getclientip = "" Then
		'如果客户端没用代理,应该用Request.ServerVariables("REMOTE_ADDR")方法
		getclientip = Request.ServerVariables("REMOTE_ADDR")
	end if
	GetIp = getclientip
end function
if UCase(changechr(Request.Form("Oper"))) = "MYFORM" then
if intMemberKey="" then
intMemberKey=0
end if

tj=changechr(Request.Form("tj"))
if tj<>"" then
tian=changechr(trim(Request.Form("InfoDate")))
pdsf=session("point")-tian
if pdsf < 0 then
response.write"<SCRIPT language=JavaScript>alert('对不起,您的点数不足,1点仅能发布一天,请返回自觉选择信息有效期!');"
response.write"javascript:history.back();</SCRIPT>"  
response.end
end if
end if
	Dim rdsInfo
	
	set rdsInfo = Server.CreateObject("ADODB.Recordset")
	rdsInfo.Open "Dat_Information",Conn,3,3

	rdsInfo.AddNew
	rdsInfo("MemberKey") = intMemberKey
	rdsInfo("Topic") = changechr(Request.Form("Topic"))
	rdsInfo("InfoClass") = changechr(Request.Form("InfoClass"))
	rdsInfo("Content") = dvHTMLEncode(Request.Form("Content"))
	rdsInfo("ContactMan") = changechr(Request.Form("ContactMan"))
	rdsInfo("CompanyName") = changechr(Request.Form("CompanyName"))
	rdsInfo("Add") = changechr(Request.Form("Add"))
	rdsInfo("Postalcode") = changechr(Request.Form("Postalcode"))
	rdsInfo("Tel") = changechr(Request.Form("Tel"))
	rdsInfo("Fax") = changechr(Request.Form("Fax"))
	rdsInfo("qq") = changechr(Request.Form("qq"))
	rdsInfo("Homepage") = changechr(Request.Form("Homepage"))
	rdsInfo("Email") = changechr(Request.Form("Email"))
	rdsInfo("InfoAdd") = changechr(Request.Form("InfoAdd"))
	rdsInfo("InfoDate") = changechr(Request.Form("InfoDate"))
	rdsInfo("dl") = changechr(Request.Form("BigClassName"))
	rdsInfo("xl") = changechr(Request.Form("SmallClassName"))
	rdsInfo("jg") = changechr(Request.Form("jg"))
	rdsInfo("pic") = changechr(Request.Form("pic"))
if changechr(Request.Form("tj"))<>"" then
	rdsInfo("tj") =1
		set rdsMember2 = Server.CreateObject("ADODB.Recordset")
		sqlMember2 = "Select * From Dat_Member Where MemberKey = "& intMemberKey
		rdsMember2.Open sqlMember2,Conn,1,3
		rdsMember2("Point") = rdsMember2("Point") -changechr(Request.Form("InfoDate"))
		rdsMember2.Update
		rdsMember2.Close
		set rdsMember2 = nothing
end if
if sh=1 then
rdsInfo("State") = 0
else
rdsInfo("State") = 1
end if
	rdsInfo("Ip") =GetIp()
	rdsInfo("CreateTime") = now()
	rdsInfo.Update
	rdsInfo.Close
	set rdsInfo = nothing
	session("point")=""
if sh=1 then
Response.write("<script>alert(""信息发布成功,请等待管理员的审核!"");location.href=""index.asp"";</script>")
Response.end
else
Response.write("<script>alert(""信息发布成功,祝您交易成功!"");location.href=""index.asp"";</script>")
Response.end
end if
end if
%>
                  <table width="450" border="0" align="center" cellpadding="1" cellspacing="2">
                  <form method="post" action="Add.asp" name="myform" OnSubmit="return addinfock()">
		          <input type="hidden" name="Oper" value="myform">
                    <tr>
                      <td width="16%" height="25">选择分类:</td>
                      <td width="84%" height="25">
						<%
		set rsb=server.createobject("adodb.recordset")
        sqlb = "select * from BigClass order by sj desc"
        rsb.open sqlb,conn,1,1
		if rsb.eof and rsb.bof then
			response.write "请先添加栏目。"
		else
		%>
                    <select name="BigClassName" onChange="changelocation(document.myform.BigClassName.options[document.myform.BigClassName.selectedIndex].value)" size="1">
                      <option selected value="<%=trim(rsb("id"))%>"><%=trim(rsb("BigClassName"))%></option>
                      <%
			dim selclass
		    selclass=cstr(rsb("id"))
        	rsb.movenext
		    do while not rsb.eof
			%>
                      <option value="<%=trim(rsb("id"))%>"><%=trim(rsb("BigClassName"))%></option>
                      <%
		        rsb.movenext
    	    loop
		end if
        rsb.close
			%>
                    </select> <select name="SmallClassName">
                      <option value="" selected>不指定小类</option>
                      <%
           set rsss=server.createobject("adodb.recordset")
			sqlss="select * from SmallClass where dl='"&selclass&"'"

⌨️ 快捷键说明

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