<!--#include file="conn.asp"-->
<!--#include file="check.asp"-->
<%
	useflag=5
%>
<!--#include file="flag.asp"-->
<!--#include file="../inc/setup.asp"-->
<%
	webid=int(Trim(Request.QueryString("id")))
	action=Trim(Request.QueryString("action"))
	ttype=Trim(Request.QueryString("ttype"))
	If webid<>"" then
		sql="select * from [ad_link] where id="&webid&""
		Set rs=server.CreateObject("adodb.recordset")
		rs.open sql,conn,1,1
	End If
	Select Case action
	case"update1"
		action="update" 
		submitname="确定修改"
		namevalue=rs("name")
		logovalue=rs("logo")
		link_logovalue=rs("link")
		type1=rs("type1")
		type2=rs("type2")
		link_art=rs("link_art")
		TitleFontColor=rs("TitleFontColor")
		shunxu=rs("shunxu")
		maxfont=rs("maxfont")
	case"add"
		submitname="确定增加"
		action="add"
		webid=""
		namevalue=""
		logovalue="http://"
		link_logovalue="http://"
		link_art="人才网--打造你我的网络神话"
		type1=1
		type2=1
	case"apply"
		submitname="确定提交"
		action="apply"
		webid=""
		namevalue=""
		logovalue="http://"
		link_logovalue="http://"
		link_art="人才网--打造你我的网络神话"
		type1=1
		alert="<font color=#ff0000>申请链接前请先做好到本站的链接！多谢合作！</font>"
	End select
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>标签类型</title>
</head>
<link href="Include/ModeWindow.css" rel="stylesheet">
<body scroll=yes topmargin="0" leftmargin="0">
<SCRIPT LANGUAGE="JavaScript">
function openScript(url, width, height){
	var Win = window.open(url,"openScript",'width=' + width + ',height=' + height + ',resizable=1,scrollbars=yes,menubar=no,status=yes' );
}
<!--
function check()
{
    if(document.userinfo.webname.value==""){
		document.userinfo.webname.focus();
    	alert("请输入网站名称！");
	return false;
  }
    if(document.userinfo.link_logo.value=="") {
	document.userinfo.link_logo.focus();
    alert("请输入网站地址！");
	return false;
  }
}
//-->
</script>
<form id="userinfo" name="userinfo" method="post" action="link_admin.asp?action=<%=action%>&id=<%=webid%>&ttype=<%= Trim(Request.QueryString("ttype")) %>" onSubmit="return check()">
<table width="100%" border="0" align="center" cellpadding="3" cellspacing="1" class='border'>
  <tr class='title'>
    <td colspan=2 align=center height=25>添加友情链接</td>
  </tr>
  <tr class='tdbg'>
    <td width="165" height="30" align="right">网站名称:</td>
    <td width="813" height="30"><input name="webname" type="text" id="webname" value="<%=namevalue%>" size="40"/></td>
  </tr>
  <tr class='tdbg' id=pass style="<% If Trim(Request.QueryString("id"))<>"" and Trim(Request.QueryString("ttype"))="wenzi" Then Response.Write("DIS")%><% If Trim(Request.QueryString("action"))="add" and Trim(Request.QueryString("ttype"))="" Then Response.Write("DIS")%>PLAY: none">
    <td align="right">logo地址:</td>
    <td height="30"><input name="logo" type="text" id="logo" value="<%=logovalue%>" size="40"/> 
      &nbsp;&nbsp;<a href="JavaScript:openScript('../upfile/uploadads.asp',320,225)">上传图片</a>&nbsp;&nbsp;(注：请填写图片的全部路径,如http://www.wishcn.com/logo.gif) </td>
  </tr>
  <tr class='tdbg'>
    <td width="165" height="30" align="right">网站地址:</td>
    <td width="813" height="30"><input name="link_logo" type="text" id="link_logo" value="<%=link_logovalue%>" size="40"/></td>
  </tr>
  <tr class='tdbg'>
    <td align="right">说明文字:</td>
    <td height="30"> <input name="link_art" type="text" id="link_art" value="<%=link_art%>" size="40"/></td>
  </tr>
  <tr class='tdbg'>
    <td align="right">链接类型:</td>
    <td height="30">
<% If ttype<>"hezuo" and ttype<>"qiye" Then %>
	<input type="radio" name="type1" value="1" <% If type1=1 Then Response.Write("checked")%> onClick="document.all.pass.style.display='none'"/>
文字链接
	  <input name="type1" type="radio" value="0" <% If type1=0 Then Response.Write("checked")%> onClick="document.all.pass.style.display='block'">
图片链接
<% End If %>
<% If ttype="qiye" Then %>
<input name="type1" type="radio" value="2" checked/>
企业广告
<% End If %>
<% If ttype="hezuo" Then %>
<input name="type1" type="radio" value="3" checked/>
合作伙伴
<% End If %>
</td>
  </tr>
  <tr class='tdbg' style="<% If type1>=2 Then Response.Write("DIS")%>PLAY: none">
  <td colspan="2">
  <table width="100%" border="0" >
<% If ttype<>"hezuo" and ttype<>"qiye" Then %>
  <tr class='tdbg'>
    <td width="152" align="right" class='tdbg'>链接位置:</td>
	<td width="823" height="30" class='tdbg'><input type="radio" name="type2" value="0" <% If type2=0 Then Response.Write("checked")%>>首页
	  <input type="radio" name="type2" value="1" <% If type2=1 Then Response.Write("checked")%>>
	  链接专用页</td>
  </tr>
  <tr class='tdbg'>
    <td align="right" class='tdbg'>字体颜色:</td>
    <td class='tdbg' height="30">&nbsp;<select id='TitleFontColor' name="TitleFontColor">
                      <option value='#000000' selected>颜色</option>
                      <option value='#000000' style='background-color:#000000' <% If TitleFontColor="#000000" Then Response.Write("selected")%>></option>
                      <option value='#FFFFFF' style='background-color:#FFFFFF' <% If TitleFontColor="#FFFFFF" Then Response.Write("selected")%>></option>
                      <option value='#008000' style='background-color:#008000' <% If TitleFontColor="#008000" Then Response.Write("selected")%>></option>
                      <option value='#800000' style='background-color:#800000' <% If TitleFontColor="#800000" Then Response.Write("selected")%>></option>
                      <option value='#808000' style='background-color:#808000' <% If TitleFontColor="#808000" Then Response.Write("selected")%>></option>
                      <option value='#000080' style='background-color:#000080' <% If TitleFontColor="#000080" Then Response.Write("selected")%>></option>
                      <option value='#800080' style='background-color:#800080' <% If TitleFontColor="#800080" Then Response.Write("selected")%>></option>
                      <option value='#808080' style='background-color:#808080' <% If TitleFontColor="#808080" Then Response.Write("selected")%>></option>
                      <option value='#FFFF00' style='background-color:#FFFF00' <% If TitleFontColor="#FFFF00" Then Response.Write("selected")%>></option>
                      <option value='#00FF00' style='background-color:#00FF00' <% If TitleFontColor="#00FF00" Then Response.Write("selected")%>></option>
                      <option value='#00FFFF' style='background-color:#00FFFF' <% If TitleFontColor="#00FFFF" Then Response.Write("selected")%>></option>
                      <option value='#FF00FF' style='background-color:#FF00FF' <% If TitleFontColor="#FF00FF" Then Response.Write("selected")%>></option>
                      <option value='#FF0000' style='background-color:#FF0000' <% If TitleFontColor="#FF0000" Then Response.Write("selected")%>></option>
                      <option value='#0000FF' style='background-color:#0000FF' <% If TitleFontColor="#0000FF" Then Response.Write("selected")%>></option>
                      <option value='#008080' style='background-color:#008080' <% If TitleFontColor="#008080" Then Response.Write("selected")%>></option>
                  </select></td>
  </tr>
<%
	if shunxu="" then shunxu=0
%>
  <tr class='tdbg'>
    <td align="right" class='tdbg'>链接顺序:</td>
    <td align="left" class='tdbg' height="30">&nbsp;<input name="shunxu" type="text" size="5" onKeyPress="if (event.keyCode < 45 || event.keyCode > 57) event.returnValue = false;" value="<%= shunxu %>">&nbsp;&nbsp;（仅能输入数字，数字越大，排列越前）</td>
  </tr>
  <tr class='tdbg'>
    <td align="right" class='tdbg'>字体加粗:</td>
    <td align="left" class='tdbg' height="30">&nbsp;<input type="radio" name="maxfont" value="0" <% If maxfont<>1 Then Response.Write("checked")%>>不加粗&nbsp;<input type="radio" name="maxfont" value="1" <% If maxfont=1 Then Response.Write("checked")%>>加粗</td>
  </tr>
<% End If %>
</table></td>
  </tr>
<tr class='tdbg'>
<td height="40" align="center" colspan="2"><input type="submit" name="Submit" value="<%=submitname%>" /> &nbsp;&nbsp;
      <input onClick="javascript:window.history.back()" type="button" value="返回"></td>
</tr>
    <tr class='tdbg'>
    <td height="30" colspan="2" align="right">
	<table width="82%" height="70" border="0" align="center">
      <tr>
        <td height="66">注：1）企业广告的位置在求职服务与兼职信息的滚动页面. 图片大小的规格为 160*70 <br><br>
&nbsp;&nbsp;&nbsp;&nbsp;2）链接位置仅对“文字链接”与“图片链接”有效<br><br>
&nbsp;&nbsp;&nbsp;&nbsp;3）合作伙伴位于网站简介信息页面内<br><br>
&nbsp;&nbsp;&nbsp;&nbsp;4）字体颜色仅对文字连接有效<br><br>
&nbsp;&nbsp;&nbsp;&nbsp;5）链接顺序仅对文字连接与图片连接有效<br><br>
&nbsp;&nbsp;&nbsp;&nbsp;6）字体加粗仅对文字连接有效</td>
      </tr>
    </table></td>
    </tr>
</table>

</form>
</body>
</html>
<%
	rs.close
	Set rs=Nothing
	conn.close
	Set conn=Nothing
%>