<% userPageRights="{admin}" %>
<!--#include file="check.asp"-->
<!--#include file="../Include/function.asp" -->
<%
dim action
act = lcase(trim(Request("act")))
if act <> "" then
ids = trim(request.Form("id"))
 
 if act = "upd" then
	dim mdyCount
	mdyCount = Request.Form("lID").Count
	if mdyCount > 0 then
		dim i
		for i = 1  to mdyCount
			Idop = CLng(trim(request.Form("lID")(i)))
			c_priceop = trim(request("t_title")(i))
			priceop = trim(request("t_links")(i))
			t_logot = trim(request("t_logo")(i))
			c_priceop2 = trim(request("t_title2")(i))
			priceop2 = trim(request("t_links2")(i))
			t_logot2 = trim(request("t_logo2")(i))
			sqlp="Update tb_news_pic Set title = '"&c_priceop&"',titleurl = '"&priceop&"',titlepic = '"&t_logot&"',title2 = '"&c_priceop2&"',titleurl2 = '"&priceop2&"',titlepic2 = '"&t_logot2&"' where Id = "& Idop &""
			conn.execute(sqlp)
		Next
	end if
end if
 
end if

lm2="tour"
%>
<STYLE>
TD {
	FONT-SIZE: 9pt; LINE-HEIGHT: 19px
}
A:link {
	COLOR:#111111; TEXT-DECORATION: none
}
A:visited {
	COLOR:#111111; TEXT-DECORATION: none
}
A:hover {
	COLOR:#EA4903; TEXT-DECORATION: underline
}
</STYLE>
<link href="../../css/DealerAdmin.css" rel="stylesheet" type="text/css">
<script language="javascript">
<!--
function upd(form){
	if(confirm("真的要更新吗?")){
		form.act.value="upd";
		form.submit();
	}
}
//-->
</script>
<script language="javascript">
<!--
function insertPic(obj){
	var file = showModalDialog("../include/filesr.asp?lm=<%=lm2%>-&path="+obj.name+"/",null,"dialogHeight:600px;dialogWidth:730px;scroll:yes;help:no;status:no;")
		if(typeof(file) != "undefined"){
		obj.value = file;
	}
}
-->
</script>
<html>
<style type="text/css">
<!--
.STYLE1 {color: #FF0000}
.style2 {font-weight: bold}
.style3 {color: #0000FF}
-->
</style>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href="../css/admin.css" rel="stylesheet" type="text/css">
</head>

<body>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr class="titleBar">
    <td height="35" valign="middle">旅游频道小图片设置</td>
  </tr>
</table>

<table width="100%"  border="0" cellpadding="0" cellspacing="0">
  <tr>
    <td height="30" align="center"><form name="form1" method="post" action="">
	<table width="96%"  border="0" align="center" cellpadding="3" cellspacing="1" bgcolor="#0099FF">
  <tr align="center" bgcolor="#FFFFFF">
    <td width="29%">链接文字</td>
    <td width="10%">所属栏目</td>
    <td width="29%">显示图片</td>
    <td width="32%">链接地址</td>
    </tr>
<%
Set rs=conn.execute("select * from tb_news_pic order by id")
do while not rs.eof
Id = rs("Id")
t_types=rs("K_name")
t_title = rs("title")
t_links = rs("titleurl")
t_logo=rs("titlepic")
t_title2 = rs("title2")
t_links2 = rs("titleurl2")
t_logo2=rs("titlepic2")
%>
   <tr align="center" id="tr<%= id %>" bgcolor="#FFFFFF" onMouseOver="javascript:this.style.backgroundColor='#CCCCFF';" onMouseOut="javascript:this.style.backgroundColor='';"> 
    <td align="center"><span class="STYLE1">左</span><input name="lID" type="hidden" id="lID" value="<%= id %>">
    <input name="t_title" type="text" id="t_title" value="<%=t_title%>" size="20" maxlength="12"></td>
    <td align="center"><%=t_types%></td>
    <td align="center"><input name="t_logo" type="text" id="t_logo" value="<%=t_logo%>" size="30"></td>
    <td align="center"><input name="t_links" type="text" id="t_links" value="<%=t_links%>" size="30" maxlength="250">
    </td>
   </tr>
   <tr align="center" bgcolor="#FFFFFF"> 
    <td align="center"><span class="style3">右</span>      <input name="t_title2" type="text" id="t_title2" value="<%=t_title2%>" size="20" maxlength="12"></td>
    <td align="center"><%=t_types%></td>
    <td align="center"><input name="t_logo2" type="text" id="t_logo2" value="<%=t_logo2%>" size="30"></td>
    <td align="center"><input name="t_links2" type="text" id="t_links2" value="<%=t_links2%>" size="30" maxlength="250">
    </td>
   </tr>
<%
rs.movenext
loop
rs.close
%> <tr bgcolor="#FFFFFF">
    <td align="center"><input name="button2" type="button" value="更新信息" onClick="javascript:upd(this.form);"></td>
    <td align="left">&nbsp;</td>
    <td align="left">&nbsp;</td>
    <td align="left"><input name="act" type="hidden" id="act"></td>
    </tr>
</table>
    <table width="100%"  border="0" cellspacing="2" cellpadding="2">
      <tr>
        <td height="37" align="right">&nbsp;</td>
        <td>上传成功后将此栏信息取掉最前面的<strong>＂..＂</strong>复制至你想设置的图片框,然后点击上面的<span class="style2">更新信息</span>完成设置，图片大小为这120px*90px</td>
      </tr>
      <tr>
        <td width="9%" height="46" align="right"><strong>图片上传：</strong></td>
        <td width="91%"><input name="sadpic" type="text" id="sadpic" value="" size="45" maxlength="255">
                <input type="button" name="Submit" value="选择&gt;" onClick="javascript:insertPic(this.form.sadpic);">
                <br>
                <span class="STYLE1"><strong></td>
      </tr>
    </table>
    </form>
    </td>
  </tr>
</table>
</body>
</html>