<!-- #include file="include/config.asp" -->
<!-- #include file="../include/jk_put.asp" -->
<!-- #include file="../include/jk_frm.asp" -->
<!-- #include file="../include/jk_email.asp" -->
<!-- #include file="../include/jk_nsort.asp" -->
<!-- #include file="../include/jk_upload.asp" -->
<!--#include file = "../common/HtmlEdit/Include/DeCode.asp"-->
<!-- #include file="../include/jk_code.asp" -->
<!-- #include file="../video/include/class.asp" -->
<!-- #include file="../include/common_pris.asp" -->
<%
web_pass=web_pass
call time_lock()
dim nsort,session_for,dim_down,types,true_hidden,true_put
session_for=joekoe_cms.web_cookies&"_put_"
go_back="<input type=button class=btn name=go_back value='返回上一页' onclick=""javascript:history.back(1);"">"
class_td=" class=tr"
tit="发布信息"

call web_head(2,1,0,0,0)
'----------------------------左边 开始----------------------------
call user_left(3)
'----------------------------左边 结束----------------------------
call web_center(0)
'----------------------------中间 开始----------------------------
%>
<table cellspacing=1 cellpadding=4 class=table>
<tr><td class=td colspan=2>&nbsp;<%response.write img_skin("m_user")&tit%></td></tr>
<tr class=trb><td height=30 colspan=2>
  <table border=0>
  <tr>
  <td><%response.write img_skin("m_")%><a href='?action=art'<%if action="art" or action="" then response.write " class=red"%>>发表文章</a></td>
  <td width=5></td>
  <td><%response.write img_skin("m_")%><a href='?action=news'<%if action="news" then response.write " class=red"%>>发布新闻</a></td>
  <td width=5></td>
  <td><%response.write img_skin("m_")%><a href='?action=down'<%if action="down" then response.write " class=red"%>>发布软件</a></td>
 <td width=5></td>
  <td><%response.write img_skin("m_")%><a href='?action=video'<%if action="video" then response.write " class=red"%>>发布影视</a></td>
  <td width=5></td>
  <td><%response.write img_skin("m_")%><a href='?action=paste'<%if action="paste" then response.write " class=red"%>>上传贴图</a></td>
   </tr><tr> 
  <td><%response.write img_skin("m_")%><a href='?action=flash'<%if action="flash" then response.write " class=red"%>>上传Flash</a></td>
  <td width=5></td>
  <td><%response.write img_skin("m_")%><a href='?action=web'<%if action="web" then response.write " class=red"%>>推荐网站</a></td>
  <td width=5></td>
    <td><%response.write img_skin("m_")%><a href='?action=flea'<%if action="flea" then response.write " class=red"%>>市场信息</a></td>
	<td width=5></td>
	    <td><%response.write img_skin("m_")%><a href='?action=pris'<%if action="pris" then response.write " class=red"%>>发布企业</a></td>
	<td width=5></td>
    <td><%response.write img_skin("m_")%><a href='?action=job'<%if action="job" then response.write " class=red"%>>发布招聘</a></td>

  </tr>
  </table>
</td></tr>
<form name=add_frm action='?action=<%response.write action%>' method=post onsubmit=<%if action="job" then%>"return job_true()"<%else%>"javascript:frm_submitonce(this);"<%end if%>>
<input type=hidden name=chk value='yes'>
<input type=hidden name=upid value=''>
<%
select case action
case "news"
  nsort=action
  index_url="news"
  data_name="news"
  tit_fir="新闻"
  call put_load(21)
  if true_put=true then
    call put_news()
  else
    call put_close("发布")
  end if
case "down"
  nsort=action
  index_url="down"
  data_name="down"
  tit_fir="软件"
  call put_load(23)
  if true_put=true then
    dim_down=split(web_down,"|")
    call put_down()
    erase dim_down
  else
    call put_close("发布")
  end if
case "paste","flash"
  nsort=action
  types=action
  if nsort="paste" then nsort="gall"
  index_url="gallery"
  data_name="gallery"
  tit_fir="贴图"
  if action="flash" then tit_fir="Flash"
  call put_load(24)
  if true_put=true then
    call put_gallery()
  else
    call put_close("上传")
  end if
case "web"
  nsort=action
  index_url="website"
  data_name="website"
  tit_fir="网站"
  call put_load(25)
  if true_put=true then
    call put_web()
  else
    call put_close("推荐")
  end if
case "video"
  nsort=action
  index_url="video"
  data_name="video"
  tit_fir="影片"
  call put_load(31)
  if true_put=true then
    call put_video()
  else
    call put_close("发布")
  end if
case "flea"
  nsort=action
  index_url="flea"
  data_name="flea"
  tit_fir="信息"
  call put_load(27)
  if true_put=true then
    if int(dim_num(27))>login_emoney then
     call admin_error("注意：发布"&tit_fir&"需要 <font class=red>"&dim_num(27)&"</font> "&web_dim(9)&"，您只拥有 <font class=blue>"&login_emoney&"</font> "&web_dim(9)&"，不够支付！")
    else
     call put_flea()
    end if
  else
    call put_close("发布")
  end if
  
  case "job"
  nsort=action
  index_url="job"
  data_name="job"
  tit_fir="招聘"
  if login_isper=true then
    call web_js_msg(1,"只有企业用户有权发布招聘信息！","user_main.asp")
  else
    if login_cname="" or isnull(login_cname) then
      call web_js_msg(1,"您还未曾填写企业履历！\n\n确定转到履历注册页面！","company_reg.asp")
    else
      if int(format_mid_num(52))=1 then
    %><script language=javascript src="style/put_job.js"></script><%
        call put_job()
      else
        call put_close("招聘")
      end if
    end if
  end if

case "pris"
  nsort=action
  index_url="pris"
  data_name="pris"
  tit_fir="企业"
  call put_load(51)
  if true_put=true then
    if int(dim_num(47))>login_emoney then
     call admin_error("注意：发布"&tit_fir&"需要 <font class=red>"&dim_num(47)&"</font> "&web_dim(9)&"，您只拥有 <font class=blue>"&login_emoney&"</font> "&web_dim(9)&"，不够支付！")
    else
     call put_pris()
    end if
  else
    call put_close("发布")
  end if

case else
  action="art"
  nsort=action
  index_url="article"
  data_name="article"
  tit_fir="文章"

  call put_load(22)
  if true_put=true then
    call put_art(index_url)
  else
    call put_close("发表")
  end if
end select
response.write vbcrlf&"</table>"
response.write ukong
'----------------------------中间 结束----------------------------
call web_end(0,0)

sub put_web()
  dim name,url,pic,ispic,username,country,lang,remark,counter,isgood,tim
  if chk() then
    name=code_admin("name",1,50)
    url=code_admin("url",1,100)
    remark=code_admin("remark",1,250)
    csid=trim(request.form("c_id"))
    if cs_nd(csid)=false then
      call admin_error("请选择 "&tit_fir&"类型 ！")
      exit sub
    end if
    if name="" or url="" or lcase(url)="http://" or remark="" then
      call admin_error(tit_fir&"名称、地址和说明 不能为空！")
      exit sub
    end if
    pic=code_admin("pic",1,100)
    username=code_admin("username",1,20)
    if symbol_name(username)=false then username=login_username
    country=code_admin("country",1,20)
    lang=code_admin("lang",1,20)
    tim=joekoe_cms.now_time
    counter=0
    isgood=false
    hidden=false
    if login_mode=""&web_pass&""  then
    hidden=true
    else
    hidden=false
    end if
    call chk_cid_sid()
    sql="select * from "&data_name
    call joekoe_cms.exec(sql,-1)
    rs.open sql,conn,1,3
    rs.addnew
    rs("c_id")=cid
    rs("s_id")=sid
    rs("name")=name
    rs("url")=url
    rs("pic")=pic
    rs("username")=username
    rs("country")=country
    rs("lang")=lang
    rs("remark")=remark
    rs("counter")=counter
    rs("isgood")=isgood
    rs("hidden")=true_hidden
    rs("tim")=tim
    rs.update
    rs.close
    call upload_note(index_url,first_id(data_name,"id"))
    call admin_msg("推荐")
    exit sub
  end if
  call form_first()
  ispic=joekoe_cms.rand_file(nsort)
%>
<tr class=tr><td width='18%'><%response.write tit_fir%>名称：</td><td width='82%'><input type=text size=60 name=name value='' maxlength=50><%response.write redx%></td></tr>
<tr class=tr><td><%response.write tit_fir%>类型：</td><td><%call chk_csid(nsort,cid,sid)%></td></tr>
<tr class=tr><td><%response.write tit_fir%>地址：</td><td><input type=text size=60 name=url value='http://' maxlength=100><%response.write redx%></td></tr>
<tr class=tr><td>国家地区：</td><td><select name=country size=1>
<option>中国</option>
<option>香港</option>
<option>台湾</option>
<option>美国</option>
<option>英国</option>
<option>日本</option>
<option>韩国</option>
<option>加拿大</option>
<option>澳大利亚</option>
<option>新西兰</option>
<option>俄罗斯</option>
<option>意大利</option>
<option>法国</option>
<option>西班牙</option>
<option>德国</option>
<option>其它国家</option>
</select>&nbsp;&nbsp;&nbsp;<%response.write tit_fir%>语言：<select name=lang size=1>
<option>简体中文</option>
<option>繁体中文</option>
<option>English</option>
<option>其它语言</option>
</select></td></tr>
<tr class=tr><td>图片说明：</td><td><input type=text name=pic value='' size=60 maxlength=100></td></tr>
<tr class=tr><td>上传图片：</td><td><iframe frameborder=0 name=upload_frame width='100%' height=30 scrolling=no src='../common/upload.asp?uppath=website&upname=<%response.write ispic%>&uptext=pic'></iframe></td></tr>
<tr class=tr>
<td valign=top class=htd><br><%response.write tit_fir%>说明：<br><=250B</td>
<td>
<table border=0><tr>
<td><textarea name=remark rows=8 cols=65></textarea></td>
<td width=5></td>
<td valign=bottom><%call textarea_resize("remark")%></td>
</tr></table>
</td>
</tr>
<%
  call submit_add()
end sub

sub put_gallery()
  dim name,ispic,spic,pic,remark,username,power,emoney,counter,tim,istop
  if chk() then
    name=code_admin("name",1,50)
    pic=code_admin("pic",1,100)
    remark=code_admin("remark",1,250)
    csid=trim(request.form("c_id"))
    if cs_nd(csid)=false then
      call admin_error("请选择 "&tit_fir&"类型 ！")
      exit sub
    end if
    if name="" or pic="" or remark="" then
      call admin_error(tit_fir&"名称、地址和说明 不能为空！")
      exit sub
    end if
    spic=code_admin("spic",1,100)
    username=code_admin("username",1,20)
    if symbol_name(username)=false then username=login_username
    power=code_admin("power",1,50)
    power=replace(power," ","")
    power=replace(power,",",".")
    emoney=trim(request.form("emoney"))
    if not isnumeric(emoney) then emoney=0
    tim=joekoe_cms.now_time
    counter=0
    istop=0
    call chk_cid_sid()
    sql="select * from "&data_name
    call joekoe_cms.exec(sql,-1)
    rs.open sql,conn,1,3
    rs.addnew
    rs("c_id")=cid
    rs("s_id")=sid
    rs("types")=types
    rs("name")=name
    rs("spic")=spic
    rs("spic")=spic
    rs("pic")=pic
    rs("remark")=remark
    rs("username")=username
    rs("power")=power
    rs("emoney")=emoney
    rs("counter")=counter
    rs("istop")=istop
    rs("hidden")=true_hidden
    rs("tim")=tim
    rs.update
    rs.close
    call upload_note(index_url,first_id(data_name,"id"))
    call admin_msg("上传")
    exit sub
  end if
  call form_first()
  ispic=joekoe_cms.rand_file(nsort)
%>
<tr class=tr><td width='18%'><%response.write tit_fir%>名称：</td><td width='82%'><input type=text size=40 name=name value='' maxlength=50><%response.write redx%></td></tr>
<tr class=tr><td><%response.write tit_fir%>分类：</td><td><%call chk_csid(nsort,cid,sid)%></td></tr>
<%ispic=joekoe_cms.rand_file(nsort)%>
<tr class=tr><td><%response.write tit_fir%>小图片：</td><td><input type=text name=spic value='' size=50 maxlength=100>&nbsp;　<a href='../common/upload.asp?uppath=gallery&upname=<%response.write ispic%>&uptext=spic' target=upload_frames>上传小图片</a></td></tr>
<%ispic=joekoe_cms.rand_file(nsort)%>
<tr class=tr><td><%response.write tit_fir%>地址：</td><td><input type=text name=pic value='' size=50 maxlength=100><%response.write redx%><a href='../common/upload.asp?uppath=gallery&upname=<%response.write ispic%>&uptext=pic' target=upload_frames>上传<%response.write tit_fir%></a></td></tr>
<tr class=tr><td>上传文件：</td><td><iframe frameborder=0 name=upload_frames width='100%' height=30 scrolling=no src='../common/upload.asp?uppath=gallery&upname=<%response.write ispic%>&uptext=pic'></iframe></td></tr>
<tr class=tr>
<td><%call frm_ubb_type(" class=tr")%></td>
<td><%call frm_ubb("add_frm","remark","&nbsp;&nbsp;",0)%></td>
</tr>
<tr class=tr><td><%response.write tit_fir%>说明：<br><br><=250字符</td>
<td>
<table border=0><tr>
<td><textarea name=remark rows=8 maxlength=250 cols=65></textarea></td>
<td width=5></td>
<td valign=bottom><%call textarea_resize("remark")%></td>
</tr></table>
</td>
</tr>
<%
  call chk_power("浏览","",1)
  call submit_add()
end sub

sub put_down()
  dim ddim,name,keyes,url,url2,homepage,sizes,types,genre,os,power,emoney,username,tim,counter,pic,ispic,remark
  if chk() then
    name=code_admin("name",1,40)
    url=code_admin("url",1,200)
    remark=request.form("remark")
    server_id=trim(request.form("server_id"))
    if not isnumeric(server_id) then server_id=0
    if int(server_id)<1 then server_id=0
    csid=trim(request.form("c_id"))
    if cs_nd(csid)=false then
      call admin_error("请选择 "&tit_fir&"类型 ！")
      exit sub
    end if
    if name="" or  remark="" then
      call admin_error(tit_fir&"标题 和 "&tit_fir&"内容 不能为空！")
      exit sub
	for i=1 to request("no")
	  if  request("url"&i&"")="" or request("filename"&i&"")="" then
        call admin_error(tit_fir&"下载地址 和 备注 不能为空！")
        exit sub
	  end if
	next
    end if
    url2=code_admin("url2",1,200)
    homepage=code_admin("homepage",1,50)
    sizes=code_admin("sizes",1,10)
    types=trim(request.form("types"))
    if not isnumeric(types) then types=0
    genre=code_admin("genre",1,5)
    os=code_admin("os",1,100)
    os=replace(os," ","")
    pic=code_admin("pic",1,100)
    keyes=code_admin("keyes",1,20)
    power=code_admin("power",1,50)
    power=replace(power," ","")
    power=replace(power,",",".")
    emoney=trim(request.form("emoney"))
    if not isnumeric(emoney) then emoney=0
    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
    counter=trim(request.form("counter"))
    if not isnumeric(counter) then counter=0
    hidden=true
    if trim(request.form("hidden"))="yes" then hidden=false
    call chk_cid_sid()
    sql="select * from "&data_name
    call joekoe_cms.exec(sql,-1)
    rs.open sql,conn,1,3
    rs.addnew
    rs("c_id")=cid
    rs("s_id")=sid
    rs("name")=name
    'rs("url")=url
    'rs("url2")=url2
    rs("homepage")=homepage
    rs("sizes")=sizes
    rs("types")=types
    rs("genre")=genre
    rs("os")=os
    rs("power")=power
    rs("emoney")=emoney
    rs("username")=username
    rs("tim")=tim
    rs("counter")=counter
    rs("hidden")=true_hidden
    rs("keyes")=keyes
    rs("pic")=pic
    rs("remark")=remark
    'rs("server_id")=server_id
    rs.update
    rs.close
	'软件下载地址无限制增加(开始)
        dim newid,filename,urltype
		sql="select * from down order by id desc"
        set rs=server.createobject("adodb.recordset")
		rs.open sql,conn,1,1
		if not rs.eof then
		newid=rs("id")
		end if
		rs.close
		if request("no")<>"" and newid<>"" then
		 for i=1 to request("no")
		 if  request("url"&i&"")="" or request("filename"&i&"")="" then
           call admin_error(tit_fir&"下载地址 和 备注 不能为空！")
           exit sub
         else
		   sql="select * from down_file where (id is null)"
                set rs=server.createobject("adodb.recordset")
		   rs.open sql,conn,1,3
		   rs.addnew
		   rs("downid")=newid
		   rs("downno")=i
		   rs("filename")=trim(request("filename"&i&""))
		   rs("url")=trim(request("url"&i&""))
           rs("urltype")=0
		   rs.update
		   rs.close
		  end if
		 next
		end if
'软件下载地址无限制增加(结束)
    call upload_note(index_url,first_id(data_name,"id"))
    call admin_msg("发布")
    exit sub
  end if
  call form_first()
  ispic=joekoe_cms.rand_file(index_url)
%>
<tr class=tr>
<td width="80"><%response.write tit_fir%>标题：</td>
<td ><input type=text name=name size=60 maxlength=40><%response.write redx%></td>
</tr>
<tr class=tr>
<td><%response.write tit_fir%>分类：</td>
<td><%call chk_csid(nsort,cid,sid)%></td>
</tr>
<tr class=tr>
<td><%response.write tit_fir%>关键字：</td>
<td><%call frm_keyes("")%></td>
</tr>
<tr class=tr>
<td><%response.write tit_fir%>发布人：</td>
<td><input type=text name=username value='<%response.write login_username%>' size=20 maxlength=20 readonly>&nbsp;&nbsp;<%call chk_emoney(0)%></td>
</tr>
<%call chk_power("下载","",1)%>
<tr class=tr>
<td>软件大小：</td><td><input type=text name=sizes value='KB' size=10 maxlength=10>&nbsp;&nbsp;授权类型：<select name=genre size=1><%
  ddim=split(dim_down(1),":")
  for i=0 to ubound(ddim)
    response.write vbcrlf&"<option>"&ddim(i)&"</option>"
  next
  erase ddim
%></select>&nbsp;&nbsp;推荐等级：<select name=types size=1>
<option value='0'>没有等级</option>
<option value='1'>一星级</option>
<option value='2'>二星级</option>
<option value='3'>三星级</option>
<option value='4'>四星级</option>
<option value='5'>五星级</option>
</select>&nbsp;五星级同时为推荐</td>
</tr>
<tr class=tr>
<td>运行环境：</td><td><%
  ddim=split(dim_down(0),":")
  for i=0 to ubound(ddim)
    response.write "<input type=checkbox name=os value='"&ddim(i)&"' class=bg_1>"&ddim(i)
  next
  erase ddim
%></td>
</tr>
<script language="javascript">
<!--
	  function setid()
	  {
	  str='';
	  if(!window.add_frm.no.value)
	   window.add_frm.no.value=1;
 	  for(i=1;i<=window.add_frm.no.value;i++)

	     str+=''+'地址'+i+'︰<input type="text" name="url'+i+'" size=38  maxlength=250>&nbsp;备注︰<input type="text" name="filename'+i+'" size=8 maxlength=250 value="下载地址'+i+'"><font color=red>*</font><BR>';
	  window.upids.innerHTML=str+'<br>';
	  }
-->
</script>
<tr class=trb>
<td>下载地址设置：</td>
<td>
设置添加地址的数量：
<input type="text" name="no" value="1" size=2> <input type="button" class="btn" name="Button" onclick="setid();" value="添加"> 
<%response.write redx%>
</td></tr>
<tr class=tr><td>下载地址：</td><td id="upids">
</td></tr>
<tr class=tr>
<td><%response.write tit_fir%>主页：</td>
<td><input type=text name=homepage value='http://' size=40 maxlength=50></td>
</tr>
<tr class=tr>
<td>发布时间：</td>
<td><input type=text name=tim value='<%response.write joekoe_cms.now_time%>' 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='0' size=6 maxlength=10>&nbsp;人次&nbsp;&nbsp;&nbsp;&nbsp;</td>
</tr>
<tr class=tr>
<td><%call frm_ubb_type(" class=tr")%></td>
<td><%call frm_ubb("add_frm","remark","&nbsp;&nbsp;",0)%></td>
</tr>
<tr class=tr>
<td valign=top><%response.write tit_fir%>内容：</td>
<td>
<table border=0><tr>
<td><textarea name=remark rows=6 cols=65></textarea></td>
<td width=5></td>
<td valign=bottom><%call textarea_resize("remark")%></td>
</tr></table>
</td>
</tr>
<tr class=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=remark' target=upload_frame>上传至内容</a></td>
</tr>
<tr class=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_add()
end sub

sub put_news()
  put_uppath="news"
  dim topic,keyes,comto,username,tim,counter,istop,pic,ispic,word,tcolor,PaginationType,MaxCharPerPage
  if chk() then
    topic=code_admin("topic",1,40)
    word=request.form("word")
    csid=trim(request.form("c_id"))
    tcolor=trim(request.form("tcolor"))
    if len(tcolor)<>6 then tcolor=""
	PaginationType=trim(request.form("PaginationType")) 
	MaxCharPerPage=trim(request.form("MaxCharPerPage"))
    if cs_nd(csid)=false then
      call admin_error("请选择 "&tit_fir&"类型 ！")
      exit sub
    end if
    if topic="" or word="" then
      call admin_error(tit_fir&"标题 和 "&tit_fir&"内容 不能为空！")
      exit sub
    end if
    keyes=code_admin("keyes",1,20)
    comto=code_admin("comto",1,20)
    username=code_admin("username",1,20)
    if symbol_name(username)=false then username=login_username
    tim=joekoe_cms.now_time
    pic=code_admin("pic",1,100)
    ispic=true
    if pic="" then ispic=false
    counter=0
    istop=0
    call chk_cid_sid()
    sql="select * from "&data_name
    call joekoe_cms.exec(sql,-1)
    rs.open sql,conn,1,3
    rs.addnew
    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")=true_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,first_id(data_name,"id"))
    call admin_msg("发布")
    exit sub
  end if
  call form_first()
  ispic=joekoe_cms.rand_file(index_url)
%>
<tr class=tr>
<td width='18%'><%response.write tit_fir%>标题：</td>
<td width='82%'><input type=text name=topic size=60 maxlength=40><%response.write redx%></td>
</tr>
<tr class=tr>
<td><%response.write tit_fir%>标题颜色：</td>
<td>#&nbsp;<input type=text name=tcolor value='' size=10 maxlength=7>&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 class=tr>
<td><%response.write tit_fir%>分类：</td>
<td><%call chk_csid(nsort,cid,sid)%></td>
</tr>
<tr class=tr>
<td><%response.write tit_fir%>关键字：</td>
<td><%call frm_keyes("")%></td>
</tr>
<tr class=tr>
<td><%response.write tit_fir%>出处：</td>
<td><input type=text name=comto size=20 maxlength=20>&nbsp;&nbsp;<%response.write tit_fir%>发布人：<input type=text name=username value='<%response.write login_username%>' size=20 maxlength=20 readonly></td>
</tr>
<%call html_edit(1,"add_frm","word"," class=tr")%>
<tr class=tr>
<td valign=top><%response.write tit_fir%>内容：</td>
<td>
<table border=0><tr>
<td><textarea name=word rows=8 cols=65></textarea></td>
<td width=5></td>
<td valign=bottom><%call textarea_resize("word")%></td>
</tr></table>
</td>
</tr>
<tr class=tr>
<td valign=top>内容分页方式：</td>
<td><select name="PaginationType" >
<option value="0" selected class=gray>不分页</option>
<option value="1">自动分页</option>
<option value="2">手动分页</option>
</select>&nbsp;&nbsp;<strong>注：</strong>手动分页符标记为 <font color="#FF0000">[pagecute]</font> ，注意大小写</td>
</tr>
<tr class=tr>
<td valign=top>自动分页字符数：</td>
<td> <input name="MaxCharPerPage" type="text" value='5000' size="8" maxlength="8">  自动分页时的每页大约字符数（包含HTML标记）</td>
</tr>
<tr class=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 class=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_add()
end sub

sub put_art(puppath)
  put_uppath=puppath
  dim topic,keyes,comto,author,power,emoney,username,tim,counter,istop,word,tcolor,PaginationType,MaxCharPerPage
  if chk() then
    topic=code_admin("topic",1,50)
    word=request.form("word")
    csid=trim(request.form("c_id"))
    tcolor=trim(request.form("tcolor"))
    PaginationType=trim(request.form("PaginationType")) 
    MaxCharPerPage=trim(request.form("MaxCharPerPage"))
    if len(tcolor)<>6 then tcolor=""
    if cs_nd(csid)=false then
      call admin_error("请选择 "&tit_fir&"类型 ！")
      exit sub
    end if
    if topic="" or word="" then
      call admin_error(tit_fir&"标题 和 "&tit_fir&"内容 不能为空！")
      exit sub
    end if
    keyes=code_admin("keyes",1,20)
    comto=code_admin("comto",1,20)
    author=code_admin("author",1,20)
    power=code_admin("power",1,50)
    power=replace(power," ","")
    power=replace(power,",",".")
    emoney=trim(request.form("emoney"))
    if not isnumeric(emoney) then emoney=0
    username=code_admin("username",1,20)
    if symbol_name(username)=false then username=login_username
    tim=joekoe_cms.now_time
    counter=0
    istop=0
    call chk_cid_sid()
    sql="select * from "&data_name
    call joekoe_cms.exec(sql,-1)
    rs.open sql,conn,1,3
    rs.addnew
    rs("c_id")=cid
    rs("s_id")=sid
    rs("cod")=cod_type()
    rs("topic")=topic
    rs("comto")=comto
    rs("author")=author
    rs("power")=power
    rs("emoney")=emoney
    rs("username")=username
    rs("tim")=tim
    rs("counter")=counter
    rs("istop")=istop
    rs("hidden")=true_hidden
    rs("keyes")=keyes
    rs("word")=word
    rs("tcolor")=tcolor
	rs("PaginationType")=PaginationType
	rs("MaxCharPerPage")=MaxCharPerPage
    rs.update
    rs.close
    call upload_note(index_url,first_id(data_name,"id"))
    call admin_msg("发表")
    exit sub
  end if
  call form_first()
%>
<tr class=tr>
<td width='18%'><%response.write tit_fir%>标题：</td>
<td width='82%'><input type=text name=topic size=60 maxlength=50><%response.write redx%></td>
</tr>
<tr class=tr>
<td><%response.write tit_fir%>标题颜色：</td>
<td>#&nbsp;<input type=text name=tcolor value='' size=10 maxlength=7>&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 class=tr>
<td><%response.write tit_fir%>分类：</td>
<td><%call chk_csid(nsort,cid,sid)%></td>
</tr>
<tr class=tr>
<td><%response.write tit_fir%>关键字：</td>
<td><%call frm_keyes("")%></td>
</tr>
<tr class=tr>
<td><%response.write tit_fir%>出处：</td>
<td><input type=text name=comto size=20 maxlength=20>&nbsp;&nbsp;<%response.write tit_fir%>作者：<input type=text name=author value='' size=20 maxlength=20></td>
</tr>
<tr class=tr>
<td><%response.write tit_fir%>发布人：</td>
<td><input type=text name=username value='<%response.write login_username%>' size=20 maxlength=20 readonly>&nbsp;&nbsp;<%call chk_emoney(0)%></td>
</tr>
<%
call chk_power("浏览","",1)
call html_edit(1,"add_frm","word"," class=tr")%>
<tr class=tr>
<td valign=top><%response.write tit_fir%>内容：</td>
<td>
<table border=0><tr>
<td><textarea name=word rows=8 cols=65></textarea></td>
<td width=5></td>
<td valign=bottom><%call textarea_resize("word")%></td>
</tr></table>
</td>
</tr>
<tr class=tr>
<td valign=top>内容分页方式：</td>
<td><select name="PaginationType" >
<option value="0" selected class=gray>不分页</option>
<option value="1">自动分页</option>
<option value="2">手动分页</option>
</select>&nbsp;&nbsp;<strong>注：</strong>手动分页符标记为 <font color="#FF0000">[pagecute]</font> ，注意大小写</td>
</tr>
<tr class=tr>
<td valign=top>自动分页字符数：</td>
<td> <input name="MaxCharPerPage" type="text" value='5000' size="8" maxlength="8">  自动分页时的每页大约字符数（包含HTML标记）</td>
</tr>
<tr class=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 left(index_url,1)%>&uptext=word'></iframe></td>
</tr>
<%
  call submit_add()
end sub

sub put_video()
  dim pic,no,url,urlname,vid,ispic,username,hidden,tim,remark,whe,role,name,power,emoney,counter,videoserver,isfree
  dim viewtype,star,vsize
  if chk() then
    name=code_admin("name",1,50)
    csid=trim(request.form("c_id"))
	no=trim(request.form("no"))
	if not int_true(no) then no=0
	videoserver=trim(request.form("videoserver"))
	if not int_true(videoserver) then videoserver=0
    if cs_nd(csid)=false then
      call admin_error("请选择 "&tit_fir&"类型 ！")
      exit sub
    end if
    if name="" then
      call admin_error(tit_fir&"标题 不能为空！")
      exit sub
    end if
    for i=1 to no
      url=code_admin("url"&i&"",1,255)
      if url="" then
        call admin_error(tit_fir&"地址"&i&" 不能为空！")
        exit sub
      end if
      if videoserver>0 and instr(url,"://")<>0 then
        call admin_error("本地服务器"&tit_fir&"地址"&i&" 错误！请输入服务器相对路径！")
        exit sub
      end if
      if videoserver=0 and instr(url,"://")<1 then
        call admin_error("非本地服务器"&tit_fir&"地址"&i&" 错误！请输入服务器绝对路径！")
        exit sub
      end if
      urlname=code_admin("urlname"&i&"",1,20)
      if urlname="" then
        call admin_error(tit_fir&"名称"&i&" 不能为空！")
        exit sub
      end if
    next
    whe=code_admin("whe",1,20)
    remark=request.form("remark")
    role=code_admin("role",1,100)
    power=code_admin("power",1,50)
    power=replace(power," ","")
    power=replace(power,",",".")
    emoney=trim(request.form("emoney"))
    if not isnumeric(emoney) then emoney=0
    pic=code_admin("pic",1,100)
	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
	counter=trim(request.form("counter"))
    if not isnumeric(counter) then counter=0
	star=trim(request.form("star"))
    if not isnumeric(star) then star=1
	viewtype=trim(request.form("viewtype"))
    if not isnumeric(viewtype) then viewtype=1
    hidden=true
    if trim(request.form("hidden"))="yes" then hidden=false
    isfree=false
    if trim(request.form("isfree"))="yes" then isfree=true
    call chk_cid_sid()
	sql="select * from "&data_name
    call joekoe_cms.exec(sql,-1)
    rs.open sql,conn,1,3
	rs.addnew
	rs("c_id")=cid
	rs("s_id")=sid
	rs("genre")=code_admin("genre",1,10)
	rs("name")=name
	rs("username")=username
	rs("lang")=code_admin("lang",1,10)
	rs("whe")=whe
	rs("remark")=remark
	rs("role")=role
    rs("hidden")=true_hidden
	rs("emoney")=emoney
	rs("power")=power
	rs("star")=star
	rs("viewtype")=viewtype
	rs("types")=code_admin("types",1,10)
	rs("pic")=pic
	rs("tim")=tim
	rs("counter")=counter
	rs("isfree")=isfree
	rs("server_id")=videoserver
    rs.update
	vid=rs("id")
	rs.close
	sql="select * from video_url where id is null"
    call joekoe_cms.exec(sql,-1)
    rs.open sql,conn,1,3
	for i=1 to no
		rs.addnew
		url=code_admin("url"&i,1,255)
		urlname=code_admin("urlname"&i,1,20)
		vsize=0
		if trim(request.form("vsize"&i))="yes" then vsize=1
		rs("nameid")=vid
		rs("url")=url
		rs("urlname")=urlname
		rs("video_size")=vsize
		rs.update
	next
	rs.close
    call upload_note(index_url,first_id(data_name,"id"))
    call admin_msg("发布")
    exit sub
  end if
  call form_first()
  ispic=joekoe_cms.rand_file(index_url)
%>
<tr class=tr>
<td width="18%"><%response.write tit_fir%>标题：</td>
<td><input type=text name=name size=60 maxlength=50><% response.write redx %></td>
</tr>
<tr class=tr width='82%'>
<td><%response.write tit_fir%>分类：</td>
<td><%call chk_csid(nsort,cid,sid)%></td>
<tr class=tr><td><%response.write tit_fir%>主演：</td><td><input type=text name=role value='未知' size=50 maxlength=100></td></tr>
</tr>
<tr class=tr>
<td><%response.write tit_fir%>发布人：</td>
<td><input type=text name=username value='<%response.write login_username%>' size=20 maxlength=20 readonly>&nbsp;&nbsp;<%call chk_emoney(1)%>&nbsp;&nbsp;免费影片：<input type=checkbox name=isfree value='yes'></td>
</tr>
<%call chk_power("影片","",1)%>
<tr class=tr>
<td>发布时间：</td>
<td><input type=text name=tim value='<%response.write joekoe_cms.now_time%>' size=20 maxlength=20>&nbsp;<input type=button class=btn name=st_btn value="选择" onclick="javascript:select_time(tim);return false;">&nbsp;&nbsp;观看&nbsp;<input type=text name=counter value='0' size=6 maxlength=10>&nbsp;人次&nbsp;&nbsp;&nbsp;&nbsp;</td>
</tr>
<tr class=tr>
<td><%response.write tit_fir%>信息：</td>
<td><%response.write tit_fir%>产地：<select size=1 name=whe><%response.write video_skin.sel_type("","大陆|台湾|香港|日韩|欧美|其他")%></select>
&nbsp;&nbsp;<%response.write tit_fir%>语种：<select size=1 name=lang><%response.write video_skin.sel_type("","汉语|粤语|英语|日语|韩语|法语|其他")%></select>
&nbsp;&nbsp;推荐等级：
<select name=star size=1>
<option value=1>一星级</option>
<option value=2>二星级</option>
<option value=3>三星级</option>
<option value=4>四星级</option>
<option value=5>五星级</option>
</select>
&nbsp;<font class=red>五星即为推荐</font>
</td>
</tr>
<tr class=tr>
<td><%response.write tit_fir%>格式：</td>
<td>
<img src='../images/video/ico_rp.gif' width=16 height=16> <input type=radio value='real' name=genre checked>
&nbsp;<img src='../images/video/ico_mov.gif' width=16 height=16> <input type=radio value='qt' name=genre>
&nbsp;<img src='../images/video/ico_wmp.gif' width=16 height=16> <input type=radio value='wmp' name=genre>
&nbsp;<%response.write tit_fir%>类型：&nbsp;<select name=types size=1>
<option value='film'>影片</option>
<option value='mtv'>MTV</option>
<option value='music'>歌曲</option>
</select>
</td>
</tr>
<tr class=tr>
<td>开放方式：</td>
<td><input type=radio value=1 name=viewtype checked>在线观看 <input type=radio value=0 name=viewtype>影片下载 <input type=radio value=2 name=viewtype>即能观看也可下载</td>
</tr>
<script language=javascript>
<!--
function seturl()
{
	var str="";
	var j="";
	var temname1=add_frm.t1.value
	var temname2=add_frm.t2.value
	if (!window.add_frm.no.value) window.add_frm.no.value=1;
	for(i=1;i<=window.add_frm.no.value;i++)
	{
	if (i<10)
	{ j='0'+i; }
	else
	{ j=i; }
	str+='&nbsp;'+j+'：&nbsp;<input type=text name="url'+i+'" size=40 value="'+temname1+j+temname2+'" maxlength=255>&nbsp;本集名称：&nbsp;<input type=text name="urlname'+i+'" size=5 maxlength=15 value="第'+j+'集">&nbsp;１６∶９<input type=checkbox name="vsize'+i+'" value="yes"><BR>';
	}
	window.addid.innerHTML=str;
}
-->
</script>
<tr  class=trb>
<td>服务器设置：</td><td>
<select size=1 name=videoserver>
<%response.write video_skin.video_selsv("")%>
</select>
前缀：<input type=text name=t1 value='' size=17>
集数：<input type=text name=no value=2 size=1>
后缀：<input type=text name=t2 value='' size=3>
<input type=button class=btn name=Button onclick="seturl();" value='设置'> <% response.write redx %></td></tr>
<tr class=tr><td><%response.write tit_fir%>地址：</td><td id="addid"></td></tr>
<tr class=tr>
<td><%call frm_ubb_type(" class=tr")%></td>
<td><%call frm_ubb("add_frm","remark","&nbsp;&nbsp;",0)%></td>
</tr>
<tr class=tr>
<td valign=top><%response.write tit_fir%>简介：</td>
<td><textarea name=remark rows=10 cols=65></textarea></td>
</tr>
<tr class=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=remark' target=upload_frame>上传至内容</a></td>
</tr>
<tr class=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_add()
end sub

sub put_flea()
  dim name,isgood,remark,nname,email,price,url,phone,types,pic,ispic,username,tim,address,otim
  if chk() then
    name=code_admin("name",1,50)
    csid=trim(request.form("c_id"))
    nname=code_admin("nname",1,100)
    email=code_admin("email",1,100)
    remark=code_admin("remark",1,250)
	address=code_admin("address",1,100)
	tim=code_admin("tim",1,20)
    tim=joekoe_cms.time_type(tim,1)
    if tim="" then tim=joekoe_cms.now_time
	otim=code_admin("otim",1,20)
    if cs_nd(csid)=false then
      call admin_error("请选择 "&tit_fir&"类型 ！")
      exit sub
    end if    
	if not(isdate(otim)) or instr(otim,"-")=0 or instr(otim,":")>0 then
      call admin_error(tit_fir&"的 <font class=red>过期时间</font> 为空或不符合规则！")
      exit sub
    end if
    if name="" or nname="" or remark="" or email_ok(email,50)=false then 
      call admin_error(tit_fir&"名称、联系人、电子邮件、"&tit_fir&"说明 为空或电子邮件不符合规则！")
      exit sub
    end if
	if trim(request.form("read"))<>"yes" then
      call admin_error("抱歉，必须阅读并同意下面的声明才能发布！")
      exit sub
    end if
    isgood=0
    username=code_admin("username",1,20)
    types=code_admin("types",1,100)  
    price=code_admin("price",1,100)
    url=code_admin("url",1,100)
    if url="http://" or isnull(url) then url=""
    phone=code_admin("phone",1,100)
    pic=code_admin("pic",1,100)
      call chk_cid_sid()
      sql="select * from "&data_name
      rs.open sql,conn,1,3
      rs.addnew
      rs("c_id")=cid
      rs("s_id")=sid
      rs("username")=login_username
      rs("types")=types
      rs("hidden")=true_hidden
      rs("name")=name
      rs("nname")=nname
      rs("remark")=remark
      rs("email")=email
      rs("price")=price
      rs("url")=url
      rs("phone")=phone
      rs("isgood")=isgood
      if len(pic)<3 then
        rs("pic")=""
      else
        rs("pic")=pic
      end if
      rs("tim")=tim
	  rs("otim")=otim
      rs("counter")=0
	  rs("address")=address
      rs.update
      rs.close
      call upload_note(index_url,first_id(data_name,"id"))
      call joekoe_cms.exec("update user_data set emoney=emoney-"&dim_num(27)&" where username='"&login_username&"'",0)
      call admin_msg("推荐")
    exit sub
  end if
  call form_first()
  ispic=joekoe_cms.rand_file(nsort)
%>
  <tr class=tr><td colspan=2 align=center height=30>发布信息注意事项：发布一条信息将扣取您 <font class=red2><%response.write dim_num(27)%></font> <%response.write joekoe_cms.web_unit%>，标有“<%response.write redx%>”为必填项。</td></tr>
  <tr class=tr>
  <td width='18%'><%response.write tit_fir%>名称：</td>
  <td width='82%'><input type=text size=50 name=name value='' maxlength=50><%response.write redx%></td>
  </tr>
  <tr class=tr>
  <td><%response.write tit_fir%>类型：</td>
  <td><%call chk_csid(nsort,cid,sid)%></td>
  </tr> 
  <tr class=tr>
  <td>供需类型：</td>
  <td><select name=types size=1>
  <option value='供方' selected>供方</option>
  <option value='求方'>求方</option>
  </select></td>
  </tr>
  <tr class=tr>
  <td>发布时间：</td>
  <td><input type=text name=tim value='<%response.write joekoe_cms.now_time%>' size=28 maxlength=40>&nbsp;<input type=button class=btn name=st_btn value="选择" onclick="javascript:select_time(tim);return false;"></td>
  </tr>
  <tr class=tr>
  <td>过期时间：</td>
  <td><input type=text name=otim value='' size=28>&nbsp;<input type=button class=btn name=st_btn value="选择" onclick="javascript:select_time(otim);return false;">&nbsp;&nbsp;<%response.write redx%></td>
  </tr>
  <tr class=tr>
  <td>联 系 人：</td>
  <td><input type=text size=10 name=nname maxlength=50><%=redx%>&nbsp;&nbsp;发 布 人：<input type=text size=11 name=username  value='<%response.write login_username%>' maxlength=50 disabled>&nbsp;&nbsp;交易价格：<input type=text size=20 name=price value='' maxlength=20></td></tr>
  <tr class=tr>
  <td>联系地址：</td>
  <td><input type=text size=62 name=address value='' maxlength=100></td>
  </tr>
  <tr class=tr>
  <td>电子邮件：</td>
  <td><input type=text size=20 name=email maxlength=50><%response.write redx%>&nbsp;&nbsp;联系电话：<input type=text size=20 name=phone value='' maxlength=50></td>
  </tr>
  <tr class=tr>
  <td>相关网址：</td>
  <td><input type=text size=54 name=url value='http://' maxlength=100></td>
  </tr>
  <tr class=tr>
  <td valign=top class=htd><br><%response.write tit_fir%>说明：<br><=250B</td>
  <td>
  <table border=0><tr>
  <td><textarea name=remark rows=8 cols=65></textarea></td>
  <td width=5></td>
  <td valign=bottom><%call textarea_resize("remark")%></td>
  </tr></table>
  </td>
  </tr>
  <tr class=tr>
  <td><%response.write tit_fir%>图片：</td>
  <td><input type=text name=pic value='<%response.write pic%>' size=40 maxlength=100></td></tr>
  <tr class=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>
  <tr class=trb>
	<td></td>
	<td height=30><input type=submit class=btn value='提交<%response.write tit_fir%>发布'>　　<input type=reset class=btn value='重新填写'>　　<input type=checkbox name=read value='yes' class=trb> 请阅读并同意下面的声明</td>
	</tr></form>
<tr><td align=middle colspan=2 class=tr>
<table class=tr>
<tbody><tr>
<td align=middle>
<fieldset style="width: 100%" align=center><legend>
<table style="border-right: #808080 1px solid; border-top: #808080 1px solid; border-left: #808080 1px solid; border-bottom: #808080 1px solid" cellspacing=0 cellpadding=0 width=200 border=0>
<tbody>
<tr><td valign=bottom align=middle height=18><font color=#ff0000><b>请您仔细阅读下面的郑重声明</b></font></td></tr>
</tbody></table></legend>
<table cellspacing=0 cellpadding=0 width="98%" align=center border=0>
<tbody>
<tr><td height=5></td></tr>
<tr><td class=htd>1、禁止发布含有色情和反动言论以及与国家法律法规相抵触的任何信息；禁止发布在网上对他人进行人身攻击评议的言论……等信息。
<br>2、信息发布者提供的信息必须是真实可靠的，不得有欺骗行为否则后果自负；每条信息的发布不得超过二百五十个字节；敬请不要进行重复发布。
<br>3、这里的信息发布是全免费的，<%response.write web_dim(1)%>对其不负任何的法律责任（由发布者自负责任敬请郑重），<%response.write web_dim(1)%>有选择和删除权。</td></tr>
<tr><td height=5></td></tr>
</tbody></table></fieldset> 
</td></tr></tbody></table>
</td></tr>
<%
end sub


sub put_pris()
  dim name,isgood,remark,dname,fname,yzbm,sname,nname,yname,email,price,url,phone,types,pic,ispic,username,hidden,tim,address
  if chk() then
    name=code_admin("name",1,50)
    csid=trim(request.form("c_id"))
    nname=code_admin("nname",1,100)
	sname=code_admin("sname",1,100)
	yname=code_admin("yname",1,100)
	dname=code_admin("dname",1,100)
	fname=code_admin("fname",1,100)
	yzbm=code_admin("yzbm",1,100)
    email=code_admin("email",1,100)
    remark=code_admin("remark",1,250)
	address=code_admin("address",1,100)
    if trim(request.form("read"))<>"yes" then
      call admin_error("抱歉，必须阅读并同意下面的声明才能发布！")
      exit sub
    end if
    if cs_nd(csid)=false then
      call admin_error("请选择 "&tit_fir&"类型 ！")
      exit sub
    end if
    if name="" or nname="" or remark="" or email_ok(email,50)=false then 
      call admin_error(tit_fir&"名称、联系人、电子邮件、"&tit_fir&"说明 为空或电子邮件不符合规则！")
      exit sub
    end if
    tim=joekoe_cms.now_time
    isgood=false
    hidden=false
    username=code_admin("username",1,20)
    types=code_admin("types",1,100)  
    price=code_admin("price",1,100)
    url=code_admin("url",1,100)
    if url="http://" or isnull(url) then url=""
    phone=code_admin("phone",1,100)
    pic=code_admin("pic",1,100)
      call chk_cid_sid()
      sql="select * from "&data_name
      rs.open sql,conn,1,3
      rs.addnew
      rs("c_id")=cid
      rs("s_id")=sid
      rs("username")=login_username
      rs("types")=types
      rs("hidden")=hidden
      rs("name")=name
      rs("dname")=dname
	  rs("fname")=fname
      rs("nname")=nname
	  rs("sname")=sname
	  rs("yname")=yname
      rs("remark")=remark
	  rs("yzbm")=yzbm
	  rs("fname")=fname
      rs("remark")=remark
      rs("email")=email
      rs("price")=price
      rs("url")=url
      rs("phone")=phone
      rs("isgood")=isgood
      if len(pic)<3 then
        rs("pic")=""
      else
        rs("pic")=pic
      end if
      rs("tim")=tim
      rs("counter")=0
	  rs("address")=address
      rs.update
      rs.close
      call upload_note(index_url,first_id(data_name,"id"))
      call joekoe_cms.exec("update user_data set emoney=emoney-"&dim_num(47)&" where username='"&login_username&"'",0)
      call admin_msg("推荐")
    exit sub
  end if
  call form_first()
  ispic=joekoe_cms.rand_file(nsort)
%>
  <tr class=bg_td><td colspan=2 align=center height=30>发布企业信息注意事项：发布一条企业信息将扣取您 <font class=red2><%response.write dim_num(47)%></font> <%response.write joekoe_cms.web_unit%>，标有“<%response.write redx%>”为必填项。</td></tr>
  <tr class=bg_td><td width='15%'><%response.write tit_fir%>名称：</td><td width='85%'><input type=text size=62 name=name value='' maxlength=50><%response.write redx%></td></tr>
  <tr class=bg_td><td><%response.write tit_fir%>类型：</td><td><%call chk_csid(nsort,cid,sid)%>；<%response.write tit_fir%>性质：<select name=types size=1><script language=javascript>
<!--
sel_type('','<%response.write pris_dim(1)%>');
-->
</script>
</select><%response.write redx%></td></tr>
  <tr class=bg_td><td>注册资金：</td><td><input type=text size=20 name=price value='' maxlength=20><%response.write redx%>万人民币&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;联 系 人：<input type=text size=10 name=nname maxlength=50><%=redx%></td></tr>
  <tr class=bg_td><td>法人代表：</td><td><input type=text size=20 name=fname value='' maxlength=20><%response.write redx%>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;注册用户：<font class=blue><%=login_username%></font></td></tr>
  <tr class=bg_td><td>员工人数：</td><td><input type=text size=20 name=yname value='' maxlength=50><%response.write redx%>个人&nbsp;&nbsp;发布时间：<input type=text  name=tim value='<%response.write joekoe_cms.now_time%>' size=20 maxlength=40>&nbsp;<input type=button name=st_btn value="选择" onclick="javascript:select_time(tim);return false;"><%response.write redx%></td></tr>
  <tr class=bg_td><td>成立时间：</td><td><input type=text name=sname value='' size=28>&nbsp;<input type=button name=st_btn value="选择" onclick="javascript:select_time(sname);return false;">&nbsp;&nbsp;<%response.write redx%></td></tr>
  <tr class=bg_td><td>所在地区：</td><td><select name=dname size=1><script language=javascript>
<!--
sel_type('','<%response.write pris_dim(2)%>');
-->
</script>
</select><%response.write redx%>&nbsp;&nbsp;邮政编码：<input type=text size=20 name=yzbm value='' maxlength=100><%response.write redx%></td></tr>
  <tr class=bg_td><td>联系地址：</td><td><input type=text size=62 name=address value='' maxlength=100><%response.write redx%></td></tr>
  <tr class=bg_td><td>联系电话：</td><td><input type=text size=20 name=phone value='' maxlength=50><%response.write redx%>&nbsp;&nbsp;电子邮件：<input type=text size=20 name=email maxlength=50><%response.write redx%></td></tr>
  <tr class=bg_td><td>相关网址：</td><td><input type=text size=54 name=url value='http://' maxlength=100></td></tr>
  <tr class=bg_td><td valign=top class=htd><br><%response.write tit_fir%>说明：<br><=250B</td><td><textarea name=remark rows=5 cols=65></textarea></td></tr>
  <tr class=bg_td>
  <td><%response.write tit_fir%>图片：</td>
  <td><input type=text name=pic value='<%response.write pic%>' size=40 maxlength=100></td></tr>
  <tr class=bg_td>
  <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>
  <tr class=bg_tds>
	<td></td>
	<td height=30><input type=submit value='提交<%response.write tit_fir%>发布'>　　<input type=reset value='重新填写'>　　<input type=checkbox name=read value='yes' class=bg_tds> 请阅读并同意下面的声明</td>
	</tr></form>
<tr><td align=middle colspan=2 class=bg_td>
<table class=bg_td>
<tbody><tr>
<td align=middle>
<fieldset style="width: 100%" align=center><legend>
<table style="border-right: #808080 1px solid; border-top: #808080 1px solid; border-left: #808080 1px solid; border-bottom: #808080 1px solid" cellspacing=0 cellpadding=0 width=200 border=0>
<tbody>
<tr><td valign=bottom align=middle height=18><font color=#ff0000><b>请您仔细阅读下面的郑重声明</b></font></td></tr>
</tbody></table></legend>
<table cellspacing=0 cellpadding=0 width="98%" align=center border=0>
<tbody>
<tr><td height=5></td></tr>
<tr><td class=htd>1、禁止发布含有色情和反动言论以及与国家法律法规相抵触的任何信息；禁止发布在网上对他人进行人身攻击评议的言论……等信息。
<br>2、信息发布者提供的信息必须是真实可靠的，不得有欺骗行为否则后果自负；每条信息的发布不得超过二百五十个字节；敬请不要进行重复发布。
<br>3、这里的信息发布是全免费的，<%response.write web_dim(1)%>对其不负任何的法律责任（由发布者自负责任敬请郑重），<%response.write web_dim(1)%>有选择和删除权。</td></tr>
<tr><td height=5></td></tr>
</tbody></table></fieldset> 
</td></tr></tbody></table>
</td></tr>
<%
end sub

sub put_job()
  if chk() then
  dim zptext,job,zpnum,gzdd,nianlings,zyes,edus,moneys,youxiaos,jobtypes
  dim sexs,shisus,hkas,hkbs,languages,computers,marrys,pthuas
  zptext=code_admin("zptext",1,500)
  job=code_admin("job",1,50)
  gzdd=trim(request.form("gzdd"))
  nianlings=trim(request.form("nianlings"))
  zpnum=trim(request.form("zpnum"))
  if not isnumeric(zpnum) then zpnum=1
  if not isnumeric(nianlings) then nianlings=20
  if job="" or zpnum="" or nianlings="" then
      call admin_error(tit_fir&"职位、人数和年龄 不能为空！")
      exit sub
  end if
  if zptext="" or len(zptext)>250 then
      call admin_error(tit_fir&"岗位描述是必须的！并且不多于250个字符！")
      exit sub
  end if
     sql="select * from "&data_name
     call joekoe_cms.exec(sql,-1)
     rs.open sql,conn,1,3
     rs.addnew
     rs("username")=login_username
     rs("zptext")=zptext
     rs("jobtypes")=trim(request("jobtypes"))
     rs("edus")=trim(request("edus"))
     rs("shisus")=trim(request("shisus"))
     rs("zyes")=trim(request("zyes"))
     rs("nianlings")=nianlings
     rs("languages")=trim(request("languages"))
     rs("hkas")=trim(request("hkas"))
     rs("pthuas")=trim(request("pthuas"))
     rs("hkbs")=trim(request("hkbs"))
     rs("sexs")=trim(request("sexs"))
     rs("marrys")=trim(request("marrys"))
     rs("computers")=trim(request("computers"))
     rs("job")=job
     rs("moneys")=trim(request("moneys"))
     rs("youxiaos")=trim(request("youxiaos"))
     rs("zpnum")=int(zpnum)
     rs("gzdd")=gzdd
     rs("tim")=joekoe_cms.now_time
     rs("cname")=login_cname
     rs("counter")=0
     rs("hidden")=0
     rs("istop")=0
     rs.update
     rs.close
     call admin_msg("发表")
     exit sub
  end if
  call form_first()
%>
<tr>
<td>
<table border=0 cellspacing=1 cellpadding=1 align=center width='100%' class=tr>
<tr align=right class=bg_td><td width='18%'>招聘职位：</td><td width='84%' colspan=3 align=left>&nbsp;<select size=1 name=job>
<script language=javascript>
<!--
sel_type('','<%response.write pris_dim(4)%>');
-->
</script>
</select>&nbsp;<%=redx%></td></tr>
<tr class=bg_td><td align=right width='18%'>工作地区：</td><td width='32%' align=left>&nbsp;<SELECT size=1 name=gzdd>
<script language=javascript>
<!--
sel_type('','<%response.write pris_dim(2)%>');
-->
</script>
</SELECT></td>
<td width='18%' align=right>有效期限：</td><td align=left width='32%'>&nbsp;<SELECT size=1 name=youxiaos>
<script language=javascript>
<!--
sel_type('','<%response.write pris_dim(6)%>');
-->
</script>
</SELECT></td></tr>
<tr align=right class=bg_td><td>招聘人数：</td><td align=left>&nbsp;<INPUT maxLength=5 size=5 name=zpnum>　人&nbsp;<%=redx%></td>
<td align=right height=25>年龄要求：</td><td align=left>&nbsp;<INPUT maxLength=2 size=4 name=nianlings>　岁&nbsp;<%=redx%></td>
</tr>
<tr align=right class=bg_td><td>专业要求：</td><td align=left>&nbsp;<SELECT size=1 name=zyes> 
<script language=javascript>
<!--
sel_type('','<%response.write pris_dim(5)%>');
-->
</script>
</SELECT></td>
<td align=right>户籍要求：</td><td align=left>&nbsp;<SELECT size=1 name=hkas>
<script language=javascript>
<!--
sel_type('','不限');
sel_type('','<%response.write pris_dim(2)%>');
-->
</script>
</SELECT></td></tr>
<tr align=right class=bg_td><td>学历要求：</td><td align=left>&nbsp;<SELECT size=1 name=edus>
<script language=javascript>
<!--
sel_type('','不限');
sel_type('','<%response.write pris_dim(7)%>');
-->
</script>
</SELECT></td>
<td align=right>目前住地：</td><td align=left>&nbsp;<SELECT size=1 name=hkbs>
<script language=javascript>
<!--
sel_type('','不限');
sel_type('','<%response.write pris_dim(2)%>');
-->
</script>
</SELECT></td></tr>
<tr align=right class=bg_td><td>外语要求：</td><td align=left>&nbsp;<SELECT size=1 name=languages>
<script language=javascript>
<!--
sel_type('','不限');
sel_type('','<%response.write pris_dim(8)%>');
-->
</script>
</SELECT></td>
<td align=right>普通话程度：</td><td align=left>&nbsp;<SELECT size=1 name=pthuas>
<script language=javascript>
<!--
sel_type('','<%response.write pris_dim(9)%>');
-->
</script>
</SELECT></td></tr>
<tr align=right class=bg_td><td>性别要求：</td><td align=left>&nbsp;<SELECT size=1 name=sexs>
<script language=javascript>
<!--
sel_type('','不限');
sel_type('','<%response.write pris_dim(10)%>');
-->
</script>
</SELECT></td>
<td align=right>工作性质：</td><td align=left>&nbsp;<SELECT size=1 name=jobtypes>
<script language=javascript>
<!--
sel_type('','<%response.write pris_dim(11)%>');
-->
</script>
</SELECT></td></tr>
<tr align=right class=bg_td><td>婚姻状况：</td><td align=left>&nbsp;<SELECT size=1 name=marrys>
<script language=javascript>
<!--
sel_type('','不限');
sel_type('','<%response.write pris_dim(12)%>');
-->
</script>
</SELECT></td>
<td align=right>计算机能力：</td><td align=left>&nbsp;<SELECT size=1 name=computers>
<script language=javascript>
<!--
sel_type('','不限');
sel_type('','<%response.write pris_dim(13)%>');
-->
</script>
</SELECT></td></tr>
<tr align=right class=bg_td><td>提供食宿：</td><td align=left>&nbsp;<SELECT size=1 name=shisus>
<script language=javascript>
<!--
sel_type('','<%response.write pris_dim(14)%>');
-->
</script>
</SELECT></td>
<td align=right>薪金水平：</td><td align=left>&nbsp;<SELECT size=1 name=moneys>
<script language=javascript>
<!--
sel_type('','<%response.write pris_dim(15)%>');
-->
</script>
</SELECT>　/月</td></tr>
<tr class=bg_td><td width='100%' colspan=4 height=25><p align=center>岗 位 职 责 描 述 及 其 它 要 求&nbsp;<%=redx%></td></tr>
<tr><td width='100%' colspan=4 height=25><p align=center><textarea rows=8 name=zptext cols=72></textarea><br></td></tr>
<tr class=bg_td><td width='100%' colspan=4 height=30><p align=center><input type=submit value='发 布 招 聘'>　　<input type=reset value='重 新 填 写'></td></tr>
</form></table>
</td></tr>
<%
end sub 



sub put_load(p_num)
  put_uppath=index_url
  dim tmp_num
  tmp_num=int(format_mid_num(p_num))
  select case int(tmp_num)
  case 1
    true_hidden=false
    true_put=true
  case 2
    true_hidden=true
    true_put=true
  case else
    true_put=false
  end select
end sub

sub put_close(tvar)
  response.write "<tr class=tr><td colspan=2 height=200 align=center><font class=red>对不起！本站暂时关闭 <font class=blue>"&tvar&tit_fir&"</font> 的功能。</font><br><br>如有需要，请与管理员联系。谢谢！</td></tr>"
end sub

sub admin_error(tvar)
  response.write vbcrlf&"<tr class=tr><td colspan=2 align=center><br>"&tvar&"<br><br>"&go_back&"<br><br></td></tr>"
end sub

function chk()
  chk=joekoe_cms.chk()
  if session(session_for&"addfrm")=false then chk=false
end function

sub form_first()
  session(session_for&"addfrm")=true
end sub

sub admin_msg(tvar)
 dim temp_js
 session(session_for&"addfrm")=false
  call joekoe_cms.exec("update user_data set integral=integral+"&int(dim_num(24))&" where username='"&login_username&"'",0)
 temp_js="已成功"&tvar&"了一个"&tit_fir&"！"
 response.write vbcrlf&"<tr class=tr><td colspan=2 align=center height=200><font class=red>已成功"&tvar&"了一个"&tit_fir&"！</font>"
 if true_hidden=false then
   response.write "<br><br>请等待管理审核通过……"
   temp_js=temp_js&"\n\n请等待管理审核通过……"
 end if
 response.write "</td></tr>"
 response.write joekoe_cms.js_put("alert("""&temp_js&""");",1)
end sub

sub submit_add()
  response.write vbcrlf&"<tr class=trb>" & _
		 vbcrlf&"<td></td>" & _
		 vbcrlf&"<td height=30><input type=submit class=btn value='提交添加'>　　<input type=reset class=btn value='重新填写'>　　"&go_back&"</td>" & _
		 vbcrlf&"</tr></form>"
end sub
%>