<!--#include file="../common/conn.asp"-->
<%
'检查用户权限
call checkuser(GetQueryString("WindowName"))


%>

<%
  Content=replace(trim(GetVariable("Content")),"'","''")
  strid=GetFormVariable("id")

if strid="" then
	'添加信息
	strsql="Insert Into web_job(j_title, j_addr, j_pay, j_count, j_detail, j_expires,  mn_id) values("
	strsql=strsql &	 "'" & GetFormVariable("title") & "', "
	strsql=strsql &	 "'" & GetFormVariable("addr") & "', "
	strsql=strsql &	 "'" & trim(GetFormVariable("pay")) & "', "
	strsql=strsql &	 "'" & trim(GetFormVariable("count")) & "', "
	strsql=strsql &	 "'" & content & "', "
	strsql=strsql &	 "'" & GetFormVariable("expires") & "',"
	strsql=strsql &	 "" & GetQueryString("mnid") & ")"
else
	'修改信息
	strsql="update web_job set "
	strsql=strsql &	 "j_title='" & GetFormVariable("title") & "', "
	strsql=strsql &	 "j_addr='" & GetFormVariable("addr") & "', "
	strsql=strsql &	 "j_pay='" & trim(GetFormVariable("pay")) & "', "
	strsql=strsql &	 "j_count='" & trim(GetFormVariable("count")) & "', "
	strsql=strsql &	 "j_detail='" & content & "', "
	strsql=strsql &	 "j_expires='" & GetFormVariable("expires") & "' "
	strsql=strsql &	" where id=" & strid
end if

conn.execute strsql,0,1
'response.Write(strSQL)

  conn.close
  set conn=nothing 
%>
<body onLoad="window.parent.opener.parent.main.location=window.parent.opener.parent.main.location;alert('保存完毕!')"></body>