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

📄 hs_news.asp

📁 65353音乐网 v1.1
💻 ASP
📖 第 1 页 / 共 2 页
字号:
<!-- #include file="include/admin_onlogin.asp" -->
<%

del_user_true=true
del_upload_true=true
index_url="news"
put_uppath=index_url
call admin_master(1,0)
call admin_cid_sid()
call admin_header(0,0)
select case jk_mod
case "istop"
  ntit="推荐"&tit_fir
  sql_add=" where hidden=1 and istop=1"
case "sh"
  ntit="待审核"&tit_fir
  sql_add=" where hidden=0"
case else
  jk_mod=""
  ntit=tit_fir&"列表"
  sql_add=" where hidden=1"
end select
%>
<tr><td align=center colspan=2 height=30>
  <table border=0>
  <tr>
  <td><a href='?'><%response.write tit_fir%>列表</a></td>
  <td width=10></td>
  <td><a href='?jk_mod=istop'<%if jk_mod="istop" then response.write " class=red"%>>推荐<%response.write tit_fir%></a></td>
  <td width=10></td>
  <td><a href='?jk_mod=sh'<%if jk_mod="sh" then response.write " class=red"%>>待审核<%response.write tit_fir%></a></td>
  <td width=10></td>
  <td><a href='?action=add&c_id=<%response.write cid%>&s_id=<%response.write sid%>'<%if action="add" then response.write " class=red"%>>添加<%response.write tit_fir%></a></td>
<%call joekoe_is_nsort_review()%>
  </tr>
  </table>
</td></tr>
<tr><td colspan=2 align=center>
  <table border=0 cellspacing=0 cellpadding=2>
  <form action='?' method=get>
  <input type=hidden name=jk_mod value='<%response.write jk_mod%>'>
  <input type=hidden name=c_id value='<%response.write cid%>'>
  <input type=hidden name=s_id value='<%response.write sid%>'>
  <tr>
  <td>搜索(<%response.write ntit%>) 关键字:</td>
  <td><input type=text name=keyword value='<%response.write trim(request.querystring("keyword"))%>' size=15 maxlength=20></td>
  <td><select name=sea_type size=1>
<option value='topic'>按标题</option>
<option value='username'>按发布人</option>
</select></td>
  <td><select name=sea_term sizs=1><option value='all'>满足所有条件</option><option value='only'>满足一个条件</option></seelct></td>
  <td><input type=submit class=btn value='搜索'></td>
  </tr>
  </form>
  </table>
</td></tr>
</table>
<%
call admin_table(1)

if action="handle" then call joekoe_go_handle()

select case action
case "clear"
  call joekoe_go_clear()
case "add"
  call joekoe_chk_add()
case "edit"
  call joekoe_chk_edit()
case else
  call joekoe_chk_main()
end select

call admin_ender(1)

sub joekoe_chk_edit()
  dim topic,keyes,comto,username,tim,counter,istop,hidden,pic,ispic,word,tcolor,PaginationType,MaxCharPerPage  
  call admin_td("编辑"&tit_fir)
  sql="select top 1 * from "&data_name&" where id="&id
  call joekoe_cms.exec(sql,-1)
  rs.open sql,conn,1,3
  if rs.eof then
    rs.close
    call admin_msg(tit_fir&"ID("&id&")不存在!","?",1)
    exit sub
  end if
  if chk() then
    PaginationType=trim(request.form("PaginationType")) 
    MaxCharPerPage=trim(request.form("MaxCharPerPage"))
    tcolor=trim(request.form("tcolor"))
    topic=code_admin("topic",1,40)
    word=request.form("word")
	if request.form("remote")=1 then word=ReplaceRemoteUrl(word,sAllowExt)
    csid=trim(request.form("c_id"))
    if len(tcolor)<>6 then tcolor=""
    if cs_nd(csid)=false then
      rs.close
      call admin_error("请选择 "&tit_fir&"类型 !")
      exit sub
    end if
    if topic="" or word="" then
      rs.close
      call admin_error(tit_fir&"标题 和 "&tit_fir&"内容 不能为空!")
      exit sub
    end if
    keyes=code_admin("keyes",1,20)
    comto=code_admin("comto",1,10)
    username=code_admin("username",1,20)
    if symbol_name(username)=false then username=login_username
    tim=code_admin("tim",1,20)
    tim=joekoe_cms.time_type(tim,1)
    if tim="" then tim=joekoe_cms.now_time
    pic=code_admin("pic",1,100)
    ispic=true
    if pic="" then ispic=false
    counter=trim(request.form("counter"))
    if not isnumeric(counter) then counter=0
    istop=0
    if trim(request.form("istop"))="yes" then istop=1
    hidden=true
    if trim(request.form("hidden"))="yes" then hidden=false
    call chk_cid_sid()
    rs("c_id")=cid
    rs("s_id")=sid
    rs("cod")=cod_type()
    rs("topic")=topic
    rs("comto")=comto
    rs("username")=username
    rs("tim")=tim
    rs("counter")=counter
    rs("istop")=istop
    rs("hidden")=hidden
    rs("keyes")=keyes
    rs("pic")=pic
    rs("ispic")=ispic
    rs("word")=word
    rs("tcolor")=tcolor
	rs("PaginationType")=PaginationType
	rs("MaxCharPerPage")=MaxCharPerPage
    rs.update
    rs.close
    call upload_note(index_url,id)
    call admin_msg("已成功编辑了一条"&tit_fir&"!","?jk_mod="&jk_mod&"&c_id="&cid&"&s_id="&sid,0)
    exit sub
  end if
  call form_first()
  cid=rs("c_id")
  sid=rs("s_id")
  pic=rs("pic")
  ispic=apart_filename(pic,1,"/")
  if ispic="" then ispic=joekoe_cms.rand_file(index_url)
%>
<form name=add_frm action='?jk_mod=<%response.write jk_mod%>&c_id=<%response.write cid%>&s_id=<%response.write sid%>&action=edit&id=<%response.write id%>' method=post>
<input type=hidden name=chk value='yes'>
<input type=hidden name=upid value=''>
<tr>
<td><%response.write tit_fir%>标题:</td>
<td><input type=text name=topic value='<%response.write rs("topic")%>' size=60 maxlength=40><%response.write redx%></td>
</tr>
<tr>
<td><%response.write tit_fir%>标题颜色:</td>
<td>#&nbsp;<input type=text name=tcolor value="<%response.write rs("tcolor")%>" maxlength=7 size=10>&nbsp;&nbsp;<a href='javascript:;' onClick="javascript:slect_color('tcolor');"><img border=0 src="../common/html_edit/images/btn_fgcolor.gif" width=23 height=22 align=absmiddle alt='点击选取主题字体颜色'></a>&nbsp;&nbsp;请正确填写<font class=red_3>6</font>位颜色代码。</td>
</tr>
<tr>
<td><%response.write tit_fir%>分类:</td>
<td><%call chk_csid(nsort,cid,sid)%></td>
</tr>
<tr>
<td><%response.write tit_fir%>关键字:</td>
<td><%call frm_keyes(rs("keyes"))%></td>
</tr>
<tr>
<td><%response.write tit_fir%>出处:</td>
<td><input type=text name=comto value='<%response.write rs("comto")%>' size=20 maxlength=10>&nbsp;&nbsp;<%response.write tit_fir%>发布人:<input type=text name=username value='<%response.write rs("username")%>' size=20 maxlength=20></td>
</tr>
<tr>
<td>发布时间:</td>
<td><input type=text name=tim value='<%response.write rs("tim")%>' size=20 maxlength=20>&nbsp;<input type=button class=btn name=st_btn value="选择" onclick="javascript:select_time(tim);return false;">&nbsp;&nbsp;浏览:<input type=text name=counter value='<%response.write rs("counter")%>' size=6 maxlength=10>&nbsp;人次&nbsp;&nbsp;推荐:<input type=checkbox name=istop value='yes'<%if rs("istop")=1 then response.write " checked"%>>&nbsp;&nbsp;&nbsp;&nbsp;隐藏/审核:<input type=checkbox name=hidden value='yes'<%if rs("hidden")=false then response.write " checked"%>></td>
</tr>
<%call html_edit(rs("cod"),"add_frm","word","")%>

<tr>
<td valign=top><%response.write tit_fir%>内容:</td>
<td>
<table border=0><tr>
<td><textarea name=word rows=8 cols=65><%response.write joekoe_cms.code_word(rs("word"))%></textarea></td>
<td width=5></td>
<td valign=bottom><%call textarea_resize("word")%></td>
</tr></table>
</td>
</tr>
<tr>
<td>保存远程图片:</td>
<td><input type=checkbox name=remote value='1'<%if request("remote")=1 then response.write" checked"%>>&nbsp;&nbsp;是否自动保存远程图片&nbsp;&nbsp;&nbsp;&nbsp;<font class=red>注:该操作是不可逆过程,请根据自身空间大小决定是否使用。</font></td>
</tr>
<tr>
<td>内容分页方式:</td>
<td><table border=0>
<tr><td width=225 height=25>
<input type=radio name=PaginationType value=0 onclick='showpagination(0)'<%if rs("PaginationType")=0 then response.write " checked"%>>不分页
<input type=radio name=PaginationType value=1 onclick='showpagination(1)'<%if rs("PaginationType")=1 then response.write " checked"%>>自动分页
<input type=radio name=PaginationType value=2 onclick='showpagination(2)'<%if rs("PaginationType")=2 then response.write " checked"%>>手动分页
</td>
<td id=showpt class=red>默认方式为不分页<td>
<td id=ptv style="DISPLAY:none" class=red><input type=text name=MaxCharPerPage size=5 maxlength=5 value='<%response.write rs("MaxCharPerPage")%>'>
</td></tr></table>
</td>
</tr>
<tr>
<td><%response.write tit_fir%>图片:</td>
<td><input type=text name=pic value='<%response.write pic%>' size=40 maxlength=100>&nbsp;&nbsp;&nbsp;<a href='../common/upload.asp?uppath=<%response.write index_url%>&upname=<%response.write ispic%>&uptext=pic' target=upload_frame>上传图片</a>&nbsp;&nbsp;<a href='../common/upload.asp?uppath=<%response.write index_url%>&upname=<%response.write left(index_url,1)%>&uptext=word' target=upload_frame>上传至内容</a></td>
</tr>
<tr>
<td>上传图片:</td>
<td><iframe frameborder=0 name=upload_frame width='100%' height=30 scrolling=no src='../common/upload.asp?uppath=<%response.write index_url%>&upname=<%response.write ispic%>&uptext=pic'></iframe></td>
</tr>
<%
  call submit_edit()
  rs.close
end sub

sub joekoe_chk_add()
  dim topic,keyes,comto,username,tim,counter,istop,hidden,pic,ispic,word,tcolor,PaginationType,MaxCharPerPage

⌨️ 快捷键说明

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