www.gusucode.com > 漂亮的地方旅游景点景观介绍网站源代码 > admin/road/lxs.asp
<!--#include file="../config.asp" --> <!--#include file="../../inc/page.asp" --> <% call zwtj() '属性///////////////////////////////////////////////////////////////// sub tssx(sx1,sx2) if sx1=1 then Response.Write("<span class=""fontr"">[置顶]<span>") end if if sx2=1 then Response.Write("<span class=""fontr"">[禁用]<span>") end if end sub function ymdh() if fid=0 then ymdh="" end if dim fpath,path,i fpath=getmc("Jw_lxsclass","id",fid,"fpath") path=split(fpath,",") for i=1 to (ubound(path)-1) ymdh=ymdh&"<a href=""?fid="&path(i)&""">"&getmc("Jw_lxsclass","id",path(i),"mc")&"</a> > " next end function '/////////////////////////////////////////////////////////////////////////////////////////////// mytit=mytit&"<a href=""?fid=0"">旅行社管理</a> > " select case action case "add" mytit=mytit&ymdh()&"添加旅行社" call add() case "del" call del() case "show","" if fid=0 then mytit=mytit&"所有旅行社" else mytit=mytit&ymdh()&"旅行社列表" end if call show() case "ups" mytit=mytit&ymdh()&"编辑旅行社" call ups() case "px" mytit=mytit&ymdh()&"旅行社排序" call cdpx() case "zd" call zd() case "qxzd" call qxzd() case "jy" call jy() case "qy" call qy() case "aadd" call aadd() case "doup" call doup() case "qqzz" call qqzz() case "tj" call tj() case "qxtj" call qxtj() end select '旅行社列表/////////////////////////////////////////////////////////////////////////////////////// sub show() if fid=0 then sql="select * from Jw_lxs order by zd desc,qz asc" else sql="select * from Jw_lxs where instr(fpath,',"&fid&",')>0 order by zd desc,"&order("Jw_lxsclass",fid) end if call record(rs,sql,1) call head() %> <link href="../inc/mm.css" rel="stylesheet" type="text/css" /> <script type="text/JavaScript"> <!-- function MM_openBrWindow(theURL,winName,features) { //v2.0 window.open(theURL,winName,features); } //--> </script> <table width="100%" border="0" cellpadding="1" cellspacing="1" bgcolor="#116BAE"> <tr> <td bgcolor="#FFFFFF"><table width="100%" border="0" cellpadding="1" cellspacing="1" bgcolor="#FFFFFF"> <tr> <td id="tit"><strong><%= mytit %> || <a href="?action=add&fid=<%= fid %>">添加旅行社 </a>|| <a href="?action=px&fid=<%= fid %>">旅行社排序</a> || <a href="lxsclass.asp">栏目管理</a></strong></td> </tr> <tr> <td> <table width="100%" border="0" cellpadding="2" cellspacing="1" bgcolor="#FFFFFF"> <form name="form1" id="form1" method="post" action=""> <tr> <td width="3%" align="center" bgcolor="#C5E0F3"><strong>ID</strong></td> <td width="42%" bgcolor="#C5E0F3"><strong>旅行社名称</strong></td> <td width="15%" align="center" bgcolor="#C5E0F3"><strong>创建人</strong></td> <td width="16%" align="center" bgcolor="#C5E0F3"><strong>所属分类</strong></td> <td width="10%" align="center" bgcolor="#C5E0F3"><strong>权重</strong></td> <td width="11%" align="center" bgcolor="#C5E0F3"><strong>操作</strong></td> <td width="3%" align="center" bgcolor="#C5E0F3"><input type="checkbox" name="selectall" onClick="selectit()"/></td> </tr> <% dim i,sz sz=20 i=sz dim bgc %> <div style="display:none"><% call fenpage(sz,rs,10) %></div> <% do while not rs.eof and i>0 if i mod 2=0 then bgc="#D2E9FF" else bgc="#D2E1EE" end if %> <tr id="r<%=rs("id")%>" bgcolor=<%= bgc %> onMouseOver="museing(r<%=rs("id")%>,0,'<%= bgc %>')" onMouseOut="museing(r<%=rs("id")%>,1,'<%= bgc %>')"> <td align="center"><%= rs("id") %></td> <td> <% If getmc("Jw_lxsclass","id",rs("fid"),"newspath")<>"" Then %> <a href="<%= getmc("Jw_lxsclass","id",rs("fid"),"newspath") %>?fid=<%= rs("fid") %>&id=<%= rs("id") %>" target="_blank"><%= rs("mc") %></a> <% Else %> <%= rs("mc") %> <% End If %> <% call tssx(rs("zd"),rs("show")) %></td> <td align="center"><%= rs("creater") %></td> <td align="center"> <% If rs("fid")=0 Then Response.Write("根目录") else Response.Write("<a href=""lxsclass.asp?action=ups&id="&rs("fid")&""">"&getmc("Jw_lxsclass","id",rs("fid"),"mc")&"</a>") end if %> </td> <td align="center"><%= rs("qz") %></td> <td align="center"><table border="0" cellpadding="2" cellspacing="0"> <tr> <td valign="bottom"><a href="?action=ups&fid=<%= fid %>&id=<%= rs("id") %>"><img src="../../images/admin/20050703091537508.gif" alt="编辑信息" width="14" height="15" border="0" align="absbottom" /></a></td> <td valign="bottom"><% If rs("show")=0 Then %> <a href="?action=jy&fid=<%= fid %>&id=<%= rs("id") %>"><img src="../../images/admin/20050703091539318.gif" alt="锁定" width="13" height="13" border="0" align="absbottom" /></a> <% Else %> <a href="?action=qy&fid=<%= fid %>&id=<%= rs("id") %>"><img src="../../images/admin/20050703091613193.gif" alt="解锁" width="12" height="13" border="0" align="absbottom" /></a> <% End If %></td> <td valign="bottom"><% If rs("zd")=0 Then %> <a href="?action=zd&fid=<%= fid %>&id=<%= rs("id") %>"><img src="../../images/admin/qxzd.gif" alt="置顶" width="16" height="16" border="0" align="absbottom" /></a> <% Else %> <a href="?action=qxzd&fid=<%= fid %>&id=<%= rs("id") %>"><img src="../../images/admin/zd.gif" alt="取消置顶" width="16" height="16" border="0" align="absbottom" /></a> <% End If %></td> <td valign="bottom"><% If rs("tj")=0 Then %> <a href="?action=tj&fid=<%= fid %>&id=<%= rs("id") %>"><img src="../../images/admin/qxtj.gif" alt="推荐" width="16" height="18" border="0" align="absbottom" /></a> <% Else %> <a href="?action=qxtj&fid=<%= fid %>&id=<%= rs("id") %>"><img src="../../images/admin/tj.gif" alt="取消推荐" width="16" height="18" border="0" align="absbottom" /></a> <% End If %></td> </tr> </table> </td> <td align="center"><input name="idstr" type="checkbox" value="<%= rs("id") %>" onclick="td_bgcolor(r<%=rs("id")%>,1);"></td> </tr> <% i=i-1 rs.movenext loop %> <tr> <td colspan="7" bgcolor="#C5E0F3"> <table width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="8%"><input name="del" type="button" class="button_1" id="del" value="删除所选" onmouseup="tjqr('您确定要删除?此操作无法逆转!','?action=del')" onmouseover="this.className='button_2'" onmouseout="this.className='button_1'"/></td> <td width="92%"><% call fenpage(sz,rs,10) %></td> </tr> </table></td> </tr> </form> </table></td> </tr> </table></td> </tr> </table> <% call recordend(rs) call connend() call foot() end sub '添加///////////////////////////////////////////////////////////////////////////////////////////// sub add() call chkqx(9,4) call head() %> <table width="100%" border="0" cellpadding="1" cellspacing="1" bgcolor="#116BAE"> <tr> <td bgcolor="#FFFFFF"><table width="100%" border="0" cellpadding="1" cellspacing="1" bgcolor="#FFFFFF"> <tr> <td id="tit"><strong><%= mytit %> || <a href="?action=px&fid=<%= fid %>">旅行社排序</a> || <a href="lxsclass.asp">栏目管理</a></strong></td> </tr> <tr> <td> <table width="100%" border="0" cellpadding="5" cellspacing="1" bgcolor="#FFFFFF"> <form action="" name="form1" id="form1" method="post"> <tr> <td width="12%" bgcolor="#D9ECF7">所属分类:</td> <td width="88%" bgcolor="#D9ECF7"> <table border="0" cellspacing="0" cellpadding="0"> <tr> <td><input name="fidstr" readonly type="text" class="inp" id="fidstr" size="40" value="<%= getlmdh("Jw_lxsclass",fid) %>" onfocus="this.className='focus'" onblur="this.className='inp'"/> <input name="fid" type="hidden" id="fid" value="<%= fid %>" /></td> <td width="40" align="center"><img src="../../images/admin/20061205172113303.gif" alt="浏览" width="27" height="20" style="cursor:hand;" onclick="MM_openBrWindow('../selfid.asp?tab=Jw_lxsclass&fid=<%= fid %>','','left=100,top=100,scrollbars=yes,resizable=yes,width=400,height=300')"/></td> </tr> </table></td> </tr> <tr> <td bgcolor="#D9ECF7">所在城市:</td> <td bgcolor="#D9ECF7"><table border="0" cellspacing="0" cellpadding="0"> <tr> <td><input name="cityidstr" readonly="readonly" type="text" class="inp" id="cityidstr" size="40" onfocus="this.className='focus'" onblur="this.className='inp'"/> <input name="cityid" type="hidden" id="cityid" /></td> <td width="40" align="center"><img src="../../images/admin/20061205172113303.gif" alt="浏览" width="27" height="20" style="cursor:hand;" onclick="MM_openBrWindow('../selcity.asp?tab=Jw_cityclass','','scrollbars=yes,resizable=yes,width=400,height=300')"/></td> </tr> </table></td> </tr> <tr> <td bgcolor="#D9ECF7">旅行社名称:</td> <td bgcolor="#D9ECF7"><table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td width="36%"><input name="mc" type="text" class="inp" id="mc" size="40" onfocus="this.className='focus'" onblur="out_mc();this.className='inp'"/></td> <td width="64%"><div id="cmc"></div></td> </tr> </table></td> </tr> <tr> <td bgcolor="#D9ECF7">关 键 字:</td> <td bgcolor="#D9ECF7"> <table border="0" cellspacing="0" cellpadding="0"> <tr> <td><input name="gjzstr" type="text" class="inp" id="gjzstr" size="40"onfocus="this.className='focus'" onblur="this.className='inp'"/> <input name="gjz" type="hidden" id="gjz" /></td> <td width="40" align="center"><img src="../../images/admin/20061205172113303.gif" alt="浏览" width="27" height="20" style="cursor:hand;" onclick="MM_openBrWindow('../selgjz.asp','','scrollbars=yes,resizable=yes,width=600,height=400')"/></td> <td><span class="fonth">可以填写或选择多个关键字,用","隔开</span></td> </tr> </table></td> </tr> <tr> <td bgcolor="#D9ECF7">浏 览:</td> <td bgcolor="#D9ECF7"><input name="hits" type="text" class="inp" id="hits" size="40"value="0" onfocus="this.className='focus'" onblur="this.className='inp'"/></td> </tr> <tr> <td bgcolor="#D9ECF7">缩 略 图:</td> <td bgcolor="#D9ECF7"><input name="simg" type="text" class="inp" id="simg" size="40" onfocus="this.className='focus'" onblur="this.className='inp'" /></td> </tr> <tr> <td bgcolor="#D9ECF7">原 图:</td> <td bgcolor="#D9ECF7"> <table border="0" cellspacing="0" cellpadding="0"> <tr> <td><input name="bimg" type="text" class="inp" id="bimg" size="40" onfocus="this.className='focus'" onblur="this.className='inp'"/></td> <td><img src="../../images/admin/img.gif" alt="上传" width="20" height="20" onclick="MM_openBrWindow('../upfile.asp?lx=1&f1=bimg&f2=simg&bj=1','','left='+(event.clientX+205)+',top='+(event.clientY+115)+',width=350,height=20')" style="cursor:hand;"/></td> </tr> </table></td> </tr> <tr> <td bgcolor="#D9ECF7">联系电话:</td> <td bgcolor="#D9ECF7"><input name="tel" type="text" class="inp" id="tel" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" /></td> </tr> <tr> <td bgcolor="#D9ECF7">传 真:</td> <td bgcolor="#D9ECF7"><input name="fax" type="text" class="inp" id="fax" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" /></td> </tr> <tr> <td bgcolor="#D9ECF7">手 机:</td> <td bgcolor="#D9ECF7"><input name="moblie" type="text" class="inp" id="moblie" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" /></td> </tr> <tr> <td bgcolor="#D9ECF7">联 系 人:</td> <td bgcolor="#D9ECF7"><input name="lxr" type="text" class="inp" id="lxr" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" /></td> </tr> <tr> <td bgcolor="#D9ECF7">联系地址:</td> <td bgcolor="#D9ECF7"><input name="address" type="text" class="inp" id="address" size="60" onFocus="this.className='focus'" onBlur="this.className='inp'" /></td> </tr> <tr> <td bgcolor="#D9ECF7">E-mail:</td> <td bgcolor="#D9ECF7"><input name="email" type="text" class="inp" id="email" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" /></td> </tr> <tr> <td bgcolor="#D9ECF7">QQ:</td> <td bgcolor="#D9ECF7"><input name="qq" type="text" class="inp" id="qq" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" /></td> </tr> <tr> <td bgcolor="#D9ECF7">Msn:</td> <td bgcolor="#D9ECF7"><input name="msn" type="text" class="inp" id="msn" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" /></td> </tr> <tr> <td bgcolor="#D9ECF7">成立时间:</td> <td bgcolor="#D9ECF7"><input name="clsj" type="text" class="inp" id="clsj" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" /></td> </tr> <tr> <td bgcolor="#D9ECF7">属 性:</td> <td bgcolor="#D9ECF7"><table border="0" cellpadding="2" cellspacing="0"> <tr> <td bgcolor="#D9ECF7">审核</td> <td bgcolor="#D9ECF7"><input name="show" type="checkbox" id="show" value="0" checked="checked" /></td> <td bgcolor="#D9ECF7">置顶</td> <td bgcolor="#D9ECF7"><input name="zd" type="checkbox" id="zd" value="1" /></td> <td bgcolor="#D9ECF7">推荐</td> <td bgcolor="#D9ECF7"><input name="tj" type="checkbox" id="tj" value="1" /></td> </tr> </table></td> </tr> <tr> <td colspan="2" bgcolor="#D9ECF7">旅行社简介:</td> </tr> <tr> <td colspan="2" bgcolor="#D9ECF7"> <input name="content" type="hidden"/> <iframe id="cons" src="../../edit/ewebeditor.htm?id=content" scrolling="no" frameborder="0" width="100%" height="350"></iframe></td> </tr> <tr> <td colspan="2" bgcolor="#D9ECF7"><div id="msg"></div></td> </tr> <tr> <td colspan="2" bgcolor="#D9ECF7"><input onclick="goo('?action=aadd')" name="go" type="button" class="button_1" id="go" value="提交" onmouseover="this.className='button_2'" onmouseout="this.className='button_1'"> <input name="reset" type="reset" class="button_1" id="reset" value="重置" onmouseover="this.className='button_2'" onmouseout="this.className='button_1'"/></td> </tr> </form> </table> </td> </tr> </table> </td> </tr> </table> <SCRIPT language="javascript" event="onkeydown" for="document"> if(event.keyCode==13&&event.srcElement.type!='button'&&event.srcElement.type!='submit'&&event.srcElement.type!='reset'&&event.srcElement.type!='textarea'&&event.srcElement.type!='') goo('?action=aadd'); </SCRIPT> <% call connend() call foot() end sub '执行添加////////////////////////////////////////////////////////////////////////////////////// sub aadd() call chkqx(9,4) dim mc,tel,fax,moblie,lxr,address,content,email,qq,msn,clsj,simg,bimg,spic,zd,show,gjzstr,tj,hits,qz,fid1,gjz,fpath,cityid fid1=getform("fid",2,1) qz=scpx("Jw_lxs",fid1) mc=getform("mc",1,1) simg=getform("simg",1,0) bimg=getform("bimg",1,0) gjzstr=getform("gjzstr",1,1) tel=getform("tel",1,1) fax=getform("fax",1,1) moblie=getform("moblie",1,1) lxr=getform("lxr",1,1) address=getform("address",1,1) content=getform("content",1,1) email=getform("email",1,1) qq=getform("qq",1,1) msn=getform("msn",1,1) clsj=getform("clsj",1,1) zd=getform("zd",2,0) show=getform("show",2,0) tj=getform("tj",2,0) hits=getform("hits",2,0) cityid=getform("cityid",2,0) fpath=getmc("jw_lxsclass","id",fid1,"fpath") if hits="" then hits=0 end if if show="" then show=0 end if if zd="" then zd=0 end if if tj="" then tj=0 end if '判断是否根栏目////////////////////////////////////////////////////////////////////////////// if fid1=0 then call errs("请选择旅行社分类") end if gjz=clgjz(gjzstr) '处理编辑器图片------------------------------------------------------------------ if spic<>"" then dim str,i str=split(spic,"|") if tjsy=0 then if sylx=0 then '图片水印 for i=0 to ubound(str)-1 if str(i)<>"" then call picsy(str(i)) call addpic(str(i)) end if next else '文字水印 for i=0 to ubound(str)-1 if str(i)<>"" then call textsy(str(i)) call addpic(str(i)) end if next end if end if end if '处理图片END--------------------------------------------------------------------- '插入记录//////////////////////////////////////////////////////////////////////////////////// call record(rs,"select top 1 * from Jw_lxs where 1=1",3) rs.addnew() rs("mc")=mc rs("qz")=qz rs("fid")=fid1 rs("fpath")=fpath rs("cityid")=cityid rs("tel")=tel rs("fax")=fax rs("moblie")=moblie rs("lxr")=lxr rs("address")=address rs("content")=content rs("email")=email rs("qq")=qq rs("msn")=msn rs("clsj")=clsj rs("simg")=simg rs("bimg")=bimg rs("spic")=spic rs("zd")=zd rs("show")=show rs("gjz")=gjz rs("tj")=tj rs("hits")=hits rs("creater")=creater rs("ctim")=now() rs("lastm")=now() rs.update() call recordend(rs) if err.number>0 then call errs("有错误发生") end if call errs(0) end sub '修改/////////////////////////////////////////////////////////////////////////////////////////// sub ups() call chkqx(9,5) set rs=conn.execute("select * from Jw_lxs where id="&id) if rs.eof then call cc("记录不存在!") end if dim gjz,str,i,gjzstr gjz=rs("gjz") if gjz<>"" then str=split(gjz,",") for i=0 to ubound(str) gjzstr=gjzstr&getmc("Jw_newskey","id",str(i),"mc")&"," next gjzstr=left(gjzstr,len(gjzstr)-1) end if call head() %> <table width="100%" border="0" cellpadding="1" cellspacing="1" bgcolor="#116BAE"> <tr> <td bgcolor="#FFFFFF"><table width="100%" border="0" cellpadding="1" cellspacing="1" bgcolor="#FFFFFF"> <tr> <td id="tit"> <strong><%= mytit %> || <a href="?action=add&fid=<%= fid %>">添加旅行社 </a>|| <a href="?action=px&fid=<%= fid %>">旅行社排序</a> || <a href="lxsclass.asp">栏目管理</a></strong></td> </tr> <tr> <td> <table width="100%" border="0" cellpadding="5" cellspacing="1" bgcolor="#FFFFFF"> <form action="" name="form1" id="form1" method="post"> <tr> <td width="12%" bgcolor="#D9ECF7">所属分类:</td> <td width="88%" bgcolor="#D9ECF7"> <table border="0" cellspacing="0" cellpadding="0"> <tr> <td><input name="fidstr" readonly type="text" class="inp" id="fidstr" size="40" value="<%= getlmdh("Jw_lxsclass",rs("fid")) %>" onfocus="this.className='focus'" onblur="this.className='inp'" /> <input name="fid" type="hidden" id="fid" value="<%= rs("fid") %>" /></td> <td width="40" align="center"><img src="../../images/admin/20061205172113303.gif" alt="浏览" width="27" height="20" style="cursor:hand;" onclick="MM_openBrWindow('../selfid.asp?tab=Jw_lxsclass&fid=<%= rs("fid") %>','','scrollbars=yes,resizable=yes,width=400,height=300')"/></td> </tr> </table></td> </tr> <tr> <td bgcolor="#D9ECF7">所在城市:</td> <td bgcolor="#D9ECF7"><table border="0" cellspacing="0" cellpadding="0"> <tr> <td><input name="cityidstr" type="text" class="inp" id="cityidstr" onfocus="this.className='focus'" onblur="this.className='inp'" value="<%= getlmdh("Jw_cityclass",rs("cityid")) %>" size="40" readonly="readonly"/> <input name="cityid" type="hidden" id="cityid" value="<%= rs("cityid") %>" /></td> <td width="40" align="center"><img src="../../images/admin/20061205172113303.gif" alt="浏览" width="27" height="20" style="cursor:hand;" onclick="MM_openBrWindow('../selcity.asp?tab=Jw_cityclass','','scrollbars=yes,resizable=yes,width=400,height=300')"/></td> </tr> </table></td> </tr> <tr> <td bgcolor="#D9ECF7">旅行社名称:</td> <td bgcolor="#D9ECF7"><table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td width="36%"><input name="mc" type="text" class="inp" id="mc" size="40" onfocus="this.className='focus'" onblur="out_mc();this.className='inp'" value="<%= rs("mc") %>"/></td> <td width="64%"><div id="cmc"></div></td> </tr> </table></td> </tr> <tr> <td bgcolor="#D9ECF7">关 键 字:</td> <td bgcolor="#D9ECF7"> <table border="0" cellspacing="0" cellpadding="0"> <tr> <td><input name="gjzstr" type="text" class="inp" id="gjzstr" size="40" value="<%= gjzstr %>" onfocus="this.className='focus'" onblur="this.className='inp'"/> <input name="gjz" type="hidden" id="gjz" value="<%= gjz %>"/></td> <td width="40" align="center"><img src="../../images/admin/20061205172113303.gif" alt="浏览" width="27" height="20" style="cursor:hand;" onclick="MM_openBrWindow('../selgjz.asp','','scrollbars=yes,resizable=yes,width=600,height=400')"/></td> <td><span class="fonth">可以填写或选择多个关键字,用","隔开</span></td> </tr> </table></td> </tr> <tr> <td bgcolor="#D9ECF7">浏 览:</td> <td bgcolor="#D9ECF7"><input name="hits" type="text" class="inp" id="hits" size="40" readonly value="<%= rs("hits") %>" onfocus="this.className='focus'" onblur="this.className='inp'"/></td> </tr> <tr> <td bgcolor="#D9ECF7">缩 略 图:</td> <td bgcolor="#D9ECF7"><input name="simg" type="text" class="inp" id="simg" size="40" onfocus="this.className='focus'" onblur="this.className='inp'" value="<%= rs("simg") %>" /></td> </tr> <tr> <td bgcolor="#D9ECF7">原 图:</td> <td bgcolor="#D9ECF7"> <table border="0" cellspacing="0" cellpadding="0"> <tr> <td><input value="<%= rs("bimg") %>" name="bimg" type="text" class="inp" id="bimg" size="40" onfocus="this.className='focus'" onblur="this.className='inp'"/></td> <td><img src="../../images/admin/img.gif" alt="上传" width="20" height="20" onclick="MM_openBrWindow('../upfile.asp?lx=1&id=<%= rs("id") %>&up=1&f1=bimg&f2=simg&bj=1&tab=Jw_lxs','','left='+(event.clientX+205)+',top='+(event.clientY+115)+',width=350,height=20')" style="cursor:hand;"/></td> </tr> </table></td> </tr> <tr> <td bgcolor="#D9ECF7">联系电话:</td> <td bgcolor="#D9ECF7"><input name="tel" type="text" class="inp" id="tel" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" value="<%= rs("tel") %>"/></td> </tr> <tr> <td bgcolor="#D9ECF7">传 真:</td> <td bgcolor="#D9ECF7"><input name="fax" type="text" class="inp" id="fax" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" value="<%= rs("fax") %>" /></td> </tr> <tr> <td bgcolor="#D9ECF7">手 机:</td> <td bgcolor="#D9ECF7"><input name="moblie" type="text" class="inp" id="moblie" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" value="<%= rs("moblie") %>" /></td> </tr> <tr> <td bgcolor="#D9ECF7">联 系 人:</td> <td bgcolor="#D9ECF7"><input name="lxr" type="text" class="inp" id="lxr" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" value="<%= rs("lxr") %>" /></td> </tr> <tr> <td bgcolor="#D9ECF7">联系地址:</td> <td bgcolor="#D9ECF7"><input name="address" type="text" class="inp" id="address" size="60" onFocus="this.className='focus'" onBlur="this.className='inp'" value="<%= rs("address") %>"/></td> </tr> <tr> <td bgcolor="#D9ECF7">E-mail:</td> <td bgcolor="#D9ECF7"><input name="email" type="text" class="inp" id="email" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" value="<%= rs("email") %>" /></td> </tr> <tr> <td bgcolor="#D9ECF7">QQ:</td> <td bgcolor="#D9ECF7"><input name="qq" type="text" class="inp" id="qq" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" value="<%= rs("qq") %>"/></td> </tr> <tr> <td bgcolor="#D9ECF7">Msn:</td> <td bgcolor="#D9ECF7"><input name="msn" type="text" class="inp" id="msn" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" value="<%= rs("msn") %>" /></td> </tr> <tr> <td bgcolor="#D9ECF7">成立时间:</td> <td bgcolor="#D9ECF7"><input name="clsj" type="text" class="inp" id="clsj" size="40" onFocus="this.className='focus'" onBlur="this.className='inp'" value="<%= rs("clsj") %>" /></td> </tr> <tr> <td bgcolor="#D9ECF7">属 性:</td> <td bgcolor="#D9ECF7"><table border="0" cellpadding="2" cellspacing="0"> <tr> <td>审核</td> <td><input name="show" type="checkbox" id="show" value="0" <% If rs("show")=0 Then Response.Write("checked") end if%>/></td> <td>置顶</td> <td><input name="zd" type="checkbox" id="zd" value="1" <% If rs("zd")=1 Then Response.Write("checked") end if%>/></td> <td bgcolor="#D9ECF7">推荐</td> <td bgcolor="#D9ECF7"><input name="tj" type="checkbox" id="tj" value="1" <% If rs("tj")=1 Then Response.Write("checked") end if%>/></td> </tr> </table></td> </tr> <tr> <td bgcolor="#D9ECF7">最后更新:</td> <td bgcolor="#D9ECF7"><input name="lastm" type="text" class="inp" id="lastm" size="50" disabled="disabled" value="<%= rs("lastm") %>" onfocus="this.className='focus'" onblur="this.className='inp'"/></td> </tr> <tr> <td colspan="2" bgcolor="#D9ECF7">旅行社简介:</td> </tr> <tr> <td colspan="2" bgcolor="#D9ECF7"> <input name="content" type="hidden" value="<%= server.HTMLEncode(rs("content")) %>" /> <iframe id="cons" src="../../edit/ewebeditor.htm?id=content" scrolling="no" frameborder="0" width="100%" height="350"></iframe></td> </tr> <tr> <td colspan="2" bgcolor="#D9ECF7"><div id="msg"></div></td> </tr> <tr> <td colspan="2" bgcolor="#D9ECF7"><input onclick="goo('?action=doup&id=<%= rs("id") %>&fid=<%= fid %>')" name="go" type="button" class="button_1" id="go" value="提交" onmouseover="this.className='button_2'" onmouseout="this.className='button_1'"> <input name="reset" type="reset" class="button_1" id="reset" value="重置" onmouseover="this.className='button_2'" onmouseout="this.className='button_1'" /></td> </tr> </form> </table> </td> </tr> </table> </td> </tr> </table> <SCRIPT language="javascript" event="onkeydown" for="document"> if(event.keyCode==13&&event.srcElement.type!='button'&&event.srcElement.type!='submit'&&event.srcElement.type!='reset'&&event.srcElement.type!='textarea'&&event.srcElement.type!='') goo('?action=doup&id=<%= id %>'); </SCRIPT> <% call connend() call foot() end sub '执行修改//////////////////////////////////////////////////////////////////////////////////// sub doup() call chkqx(9,5) dim mc,tel,fax,moblie,lxr,address,content,email,qq,msn,clsj,simg,bimg,spic,zd,show,gjzstr,tj,hits,fid1,gjz,fpath,cityid mc=getform("mc",1,1) fid1=getform("fid",2,1) simg=getform("simg",1,0) bimg=getform("bimg",1,0) gjzstr=getform("gjzstr",1,1) tel=getform("tel",1,1) fax=getform("fax",1,1) moblie=getform("moblie",1,1) lxr=getform("lxr",1,1) address=getform("address",1,1) content=getform("content",1,1) email=getform("email",1,1) qq=getform("qq",1,1) msn=getform("msn",1,1) clsj=getform("clsj",1,1) zd=getform("zd",2,0) show=getform("show",2,0) tj=getform("tj",2,0) hits=getform("hits",2,0) cityid=getform("cityid",2,0) fpath=getmc("jw_lxsclass","id",fid1,"fpath") if hits="" then hits=0 end if if show="" then show=0 end if if zd="" then zd=0 end if if tj="" then tj=0 end if dim fidy,spicy fidy=getmc("Jw_lxs","id",id,"fid") spicy=getmc("Jw_lxs","id",id,"spic") '判断是否根栏目////////////////////////////////////////////////////////////////////////////// if fid1=0 then call errs("不能将旅行社移到根目录下") end if gjz=clgjz(gjzstr) '删除没用到的图片//////////////////////////////////////////////////////////////////////// dim picstr,i,spicstr if spic<>spicy then picstr=split(spicy,"|") for i=0 to ubound(picstr)-1 if instr(spic,picstr(i))=0 then call delfile(picstr(i)) end if next end if spicstr=split(spic,"|") for i=0 to ubound(spicstr) if instr(spicy,spicstr(i))=0 then '插入文件表,加水印 if spicstr(i)<>"" then if tjsy=0 then if sylx=0 then '图片水印 call picsy(spicstr(i)) call addpic(spicstr(i)) else '文字水印 call textsy(spicstr(i)) call addpic(spicstr(i)) end if end if end if end if next '更新记录//////////////////////////////////////////////////////////////////////////////////// call record(rs,"select * from Jw_lxs where id="&id,3) rs("mc")=mc rs("fid")=fid1 rs("fpath")=fpath rs("tel")=tel rs("fax")=fax rs("moblie")=moblie rs("lxr")=lxr rs("address")=address rs("content")=content rs("email")=email rs("qq")=qq rs("msn")=msn rs("clsj")=clsj rs("simg")=simg rs("bimg")=bimg rs("spic")=spic rs("zd")=zd rs("show")=show rs("gjz")=gjz rs("tj")=tj rs("hits")=hits rs("cityid")=cityid rs("lastm")=now() rs.update call recordend(rs) call zhgx("Jw_lxs",id) '结束///////////////////////////////////////////////////////////////////////////////////// if err.number>0 then call errs("有错误发生") end if call errs(0) end sub '删除////////////////////////////////////////////////////////////////////////////////////////// sub del() call chkqx(9,6) dim dpic,j dim idstr,iid,i idstr=replace(Trim(Request.Form("idstr"))," ","") iid=split(idstr,",") for i=0 to ubound(iid) '删除旅行社 set rs=conn.execute("select * from Jw_lxs where id="&iid(i)) if not rs.eof then '删除小图 if not rs("simg")="" then call delfile(rs("simg")) end if if not rs("bimg")="" then call delfile(rs("bimg")) end if '删除编辑器中的图片 if not rs("spic")="" then dpic=split(rs("spic"),"|") for j=0 to ubound(dpic) call delfile(dpic(j)) next set j=nothing end if end if call recordend(rs) '删除旅行社 conn.execute("delete * from Jw_lxs where id="&iid(i)) next call connend() response.Redirect(request.ServerVariables("HTTP_REFERER")) end sub '旅行社排序/////////////////////////////////////////////////////////////////////////////// sub cdpx() call chkqx(9,5) if fid=0 then sql="select * from Jw_lxs order by zd desc,"&order("Jw_lxsclass",fid) else sql="select * from Jw_lxs where fid="&fid&" order by zd desc,"&order("Jw_lxsclass",fid) end if call record(rs,sql,1) call head() %> <table width="100%" border="0" cellpadding="1" cellspacing="1" bgcolor="#116BAE"> <tr> <td bgcolor="#FFFFFF"><table width="100%" border="0" cellpadding="1" cellspacing="1" bgcolor="#FFFFFF"> <tr> <td id="tit"><strong><%= mytit %> || <a href="?action=add&fid=<%= fid %>">添加旅行社 </a>|| <a href="?action=px&fid=<%= fid %>">旅行社排序</a> || <a href="lxsclass.asp">栏目管理</a></strong></td> </tr> <tr> <td> <table width="100%" border="0" cellpadding="4" cellspacing="1" bgcolor="#FFFFFF"> <tr> <td width="2%" align="center" bgcolor="#D9ECF7"><strong>ID</strong></td> <td width="43%" bgcolor="#D9ECF7"><strong>旅行社名称</strong></td> <td width="29%" align="center" bgcolor="#D9ECF7"><strong>权重</strong></td> </tr> <% dim i,sz sz=20 i=sz dim bgc %> <div style="display:none"><% call fenpage(sz,rs,10) %></div> <% do while not rs.eof and i>0 if i mod 2=0 then bgc="#D2E9FF" else bgc="#D2E1EE" end if %> <form action="?action=qqzz&fid=<%= fid %>&id=<%= rs("id") %>" name="form" id="form" method="post"> <tr id="r<%=rs("id")%>" bgcolor=<%= bgc %> onMouseOver="museing(r<%=rs("id")%>,0,'<%= bgc %>')" onMouseOut="museing(r<%=rs("id")%>,1,'<%= bgc %>')"> <td align="center"><%= rs("id") %></td> <td><%= rs("mc") %></td> <td align="center"><input name="qz" type="text" class="btn2" id="qz" size="8" value="<%= rs("qz") %>"><input name="Submit" type="submit" class="btn2" value="更新"></td> </tr> </form> <% i=i+1 rs.movenext loop %> <tr> <td colspan="3" bgcolor="#EAF4FB"><% call fenpage(sz,rs,10) %></td> </tr> </table></td> </tr> </table></td> </tr> </table> <% call recordend(rs) call connend() call foot() end sub '执行排序////////////////////////////////////////////////////////////////////////////// sub qqzz() if fid="" then fid=getmc("Jw_lxs","id",id,"fid") end if call dopx("Jw_lxs",fid,id,Trim(Request.Form("qz"))) call connend() response.Redirect(request.ServerVariables("HTTP_REFERER")) end sub '置顶////////////////////////////////////////////////////////////////////////////////////// sub zd() call chkqx(9,5) dim val val=1 if id<>"" then call uptab("Jw_lxs","zd",val,"id",id) call zhgx("Jw_lxs",id) end if call connend() response.Redirect(request.ServerVariables("HTTP_REFERER")) end sub '取消置顶////////////////////////////////////////////////////////////////////////////////////// sub qxzd() call chkqx(9,5) dim val val=0 if id<>"" then call uptab("Jw_lxs","zd",val,"id",id) call zhgx("Jw_lxs",id) end if call connend() response.Redirect(request.ServerVariables("HTTP_REFERER")) end sub '禁用////////////////////////////////////////////////////////////////////////////////////// sub jy() call chkqx(9,5) dim val val=1 if id<>"" then call uptab("Jw_lxs","show",val,"id",id) call zhgx("Jw_lxs",id) end if call connend() response.Redirect(request.ServerVariables("HTTP_REFERER")) end sub '起用////////////////////////////////////////////////////////////////////////////////////// sub qy() call chkqx(9,5) dim val val=0 if id<>"" then call uptab("Jw_lxs","show",val,"id",id) call zhgx("Jw_lxs",id) end if call connend() response.Redirect(request.ServerVariables("HTTP_REFERER")) end sub '推荐////////////////////////////////////////////////////////////////////////////////////// sub tj() call chkqx(9,5) dim val val=1 if id<>"" then call uptab("Jw_lxs","tj",val,"id",id) call zhgx("Jw_lxs",id) end if call connend() response.Redirect(request.ServerVariables("HTTP_REFERER")) end sub '取消推荐////////////////////////////////////////////////////////////////////////////////////// sub qxtj() call chkqx(9,5) dim val val=0 if id<>"" then call uptab("Jw_lxs","tj",val,"id",id) call zhgx("Jw_lxs",id) end if call connend() response.Redirect(request.ServerVariables("HTTP_REFERER")) end sub %> <script language="javascript" src="/<%= hturl %>/inc/chk.js"></script> <script language="javascript"> function InsertHTML(val) {var oEditor = FCKeditorAPI.GetInstance('content') ; if ( oEditor.EditMode == FCK_EDITMODE_WYSIWYG ) {oEditor.InsertHtml(val);} else alert("请切换到编辑模式");} function goo(act) { var chk=true; if (!out_mc()){chk=false;} if (!out_content()){chk=false;} if (chk==true){ GE("go").disabled="disabled"; GE("reset").disabled="disabled"; //GE("form1").action="?action=doup&id=<%= id %>"; //GE("form1").submit() var fid=GE("fid").value; var mc=escape(GE("mc").value); var tel=escape(GE("tel").value); var fax=escape(GE("fax").value); var moblie=escape(GE("moblie").value); var lxr=escape(GE("lxr").value); var address=escape(GE("address").value); var content=escape(cons.getHTML()); var email=escape(GE("email").value); var qq=escape(GE("qq").value); var msn=escape(GE("msn").value); var clsj=escape(GE("clsj").value); var simg=escape(GE("simg").value); var bimg=escape(GE("bimg").value); var show=escape(GE("show").value); var gjzstr=escape(GE("gjzstr").value); var hits=escape(GE("hits").value); var cityid=escape(GE("cityid").value); var show; if(GE("show").checked) {show=0;} else{show=1;} var zd; if(GE("zd").checked) {zd=1;} else{zd=0;} var tj; if(GE("tj").checked) {tj=1;} else{tj=0;} var Ajax = new oAjax(act,backs); var arrKey = new Array("fid","mc","tel","fax","moblie","lxr","address","content","email","qq","msn","clsj","simg","bimg","zd","show","gjzstr","tj","hits","cityid"); var arrValue =new Array(fid,mc,tel,fax,moblie,lxr,address,content,email,qq,msn,clsj,simg,bimg,zd,show,gjzstr,tj,hits,cityid); Ajax.Post(arrKey,arrValue); GE("msg").innerHTML=loading; function backs(str) { if(str=="0") { GE("msg").innerHTML=ok+" 操作成功"; window.location.href="?fid=<%= fid %>" } else { GE("msg").className="d_err"; GE("msg").innerHTML=err+" "+unescape(str); GE("go").disabled=""; GE("reset").disabled=""; } } } } </script>