<%@ page language="VB" autoeventwireup="false" inherits="qiye_admin_admin_gg, App_Web_admin_gg.aspx.25f04327" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
<link href="css/body.css" rel="stylesheet" type="text/css" />
<link href="css/css.css" rel="stylesheet" type="text/css" />
<link href="css/text.css" rel="stylesheet" type="text/css" />
<link href="css/button.css" rel="stylesheet" type="text/css" />
<script src="js/web_alt.js" type="text/javascript"></script>
<script src="js/tanbox.js" type="text/javascript"></script>


<script charset="utf-8" src="../kindeditor/kindeditor.js" type="text/javascript"></script>
<script charset="utf-8" src="../kindeditor/lang/zh_CN.js" type="text/javascript"></script>
<script charset="utf-8" src="js/kindeditor_admin.js" type="text/javascript"></script>

<script language="javascript" type="text/javascript">
    KindEditor_admin('add_gg_html', 1)
	
function CheckAll(form) //传一个表单作参数
{ 
for (var i=0;i<form.elements.length;i++) //对这个表单里的元素进行循环
{ 
var e = form.elements[i]; //一个一个元素判断
if (e.Name != "gg_int_id"&&e.disabled!=true) //如果该元素的name属性为chkAll并且disabled!=true.即:该控件可用时.
e.checked = form.chkAll.checked; //控元素的checked与当前选中的控件checked保持一致.即:全选/全不选.
} 
} 

   function copyToClipBoard(a){ 
    window.clipboardData.setData("Text",a); 
    alert("复制成功！"); 
} 

    function img_mappath(img_val, input_val) {
	var arr = showModalDialog("admin_select_img.aspx?temp="+ Math.random , "", "dialogWidth:963px; dialogHeight:600px; status:0; help:0");
        if (arr != null) {
            document.getElementById(input_val).value = arr;
        }
    }

    </script>
    <title>广告管理</title></head>
    <body>
<form id="form1" runat="server">
<%If ubb.xml_tables("red_parrot.xml", "parrot_guanguao") = "True" Then%>
<table width="100%" border="0" cellspacing="3" cellpadding="0">
  <tr>
    <td><table width="100%" border="0" cellpadding="0" cellspacing="0">
      <tr>
        <td bgcolor="#E7E7E7"><table width="100%" border="0" cellspacing="1" cellpadding="0">
          <tr>
            <td bgcolor="#FFFFFF"><table width="100%" height="29" border="0" cellpadding="0" cellspacing="5">
              <tr>
                <td height="19" bgcolor="#EBEBEB"><table width="100%" border="0" cellspacing="8" cellpadding="0">
                  
                  <tr>
                    <td bgcolor="#FFFFFF"><table width="100%" border="0" cellspacing="3" cellpadding="0">
                      <tr>
                        <td width="15%" height="25" align="center" class="wuse16"><strong class="16huise">管理中心</strong></td>
                        <td valign="bottom" class="huise12">广告管理</td>
                        <td valign="bottom" align="right" class="huise12">#n_b[ID]，#n_t[ID]，#c_b[ID]，#c_t[ID]，#b_b[ID]，#b_t[ID]，#z_t[ID]，#z_l[catgoryID]</td>
                      </tr>
                    </table></td>
                  </tr>
                </table></td>
              </tr>
            </table></td>
          </tr>
          
          
        </table></td>
      </tr>
    </table></td>

  </tr>
</table> 
   <%end if %>
   
   <fieldset style="margin:10px 5px 5px 5px; padding:0px 5px 5px 5px;"><legend class="wuse12"><strong>添加新广告</strong></legend>

   <table width="100%" border="1" cellpadding="0" cellspacing="1" bordercolor="#E7E7E7" style="margin-top:5px;">
     <tr>
       <td width="21%" height="30" align="center" bgcolor="#F6F6F6" class="wuse12">广告显示方式：</td>
       <td height="25"><asp:DropDownList ID="add_gg_fs" runat="server">
           <asp:ListItem Value="photo">图片</asp:ListItem>
           <asp:ListItem Value="html">代码</asp:ListItem>
         </asp:DropDownList>
       </td>
     </tr>
     <tr>
       <td width="21%" height="30" align="center" bgcolor="#F6F6F6" class="wuse12">广告显示位置：</td>
       <td height="25"><asp:DropDownList ID="add_gg_wz" runat="server"></asp:DropDownList></td>
     </tr>
     <tr>
       <td height="30" align="center" bgcolor="#F6F6F6" class="wuse12">广告显示图片：</td>
       <td height="25"><asp:TextBox ID="add_gg_page" runat="server" 
                                                  CssClass="text_autox22_cccccc" Width="400px" MaxLength="255"></asp:TextBox>
         <a href="javascript:img_mappath(this,'add_gg_page');" class="wuse12">打开图象库</a></td>
     </tr>
     <tr>
       <td height="30" align="center" bgcolor="#F6F6F6" class="wuse12">广告显示排序：</td>
       <td height="25"><table border="0" cellspacing="0" cellpadding="0">
           <tr>
             <td><asp:TextBox ID="add_gg_px" runat="server" 
                                                  CssClass="text_autox22_cccccc" onkeydown="intjs()" Width="50px" MaxLength="10">0</asp:TextBox></td>
             <td width="65" align="right" class="wuse12">约显码：</td>
             <td><span class="hongse12">
               <asp:TextBox ID="add_jsnumber" runat="server" 
                                CssClass="text_autox22_cccccc" Width="50px" onkeydown="intjs()" MaxLength="10"></asp:TextBox>
             </span></td>
           </tr>
       </table></td>
     </tr>
     <tr>
       <td height="30" align="center" bgcolor="#F6F6F6" class="wuse12">广告转向URL：</td>
       <td height="25"><asp:TextBox ID="add_gg_url" runat="server" 
                                                  CssClass="text_autox22_cccccc" Width="560px" MaxLength="255"></asp:TextBox></td>
     </tr>
     <tr>
       <td height="30" align="center" bgcolor="#F6F6F6" class="wuse12">广告显示说明：</td>
       <td height="25"><asp:TextBox ID="add_gg_sm" runat="server" CssClass="text_autox22_cccccc" 
                                MaxLength="50" Width="560px"></asp:TextBox></td>
     </tr>
     <tr>
       <td height="30" colspan="2" align="center" bgcolor="#F6F6F6" class="wuse12">广告Html代码：</td>
     </tr>
     <tr>
       <td height="30" colspan="2" class="wuse12"><asp:TextBox ID="add_gg_html" runat="server" CssClass="text_autox22_cccccc" 
                                                  TextMode="MultiLine" Height="150px" Width="100%"></asp:TextBox></td>
     </tr>
     <tr>
       <td height="30" align="center" bgcolor="#F6F6F6"><span 
                                                  class="wuse12"><a href="?">显示所有广告</a></span></td>
       <td height="25"><%If ubb.xml_tables("red_parrot.xml", "parrot_guanguaoadddefault") = "True" Then%>
           <asp:Button ID="add_gg_ok" runat="server" CssClass="btn1_mouseout" Text=" 添加广告 " />     
           <%End If%>
           <asp:Button ID="up_gg_ok" runat="server" CssClass="btn_2k3" Text=" 修改广告 " 
                                                  Enabled="False" />     
           <asp:Label ID="add_gg_ts" runat="server" CssClass="hongse12"></asp:Label></td>
     </tr>
   </table>
   </fieldset>
<fieldset style="margin:10px 5px 5px 5px; padding:0px 5px 5px 5px;"><legend class="wuse12"><strong>已建立的广告项</strong></legend>

<table width="100%" border="1" cellpadding="0" cellspacing="1" bordercolor="#F6F6F6" style="margin-top:5px;">
  <tr>
    <td width="21" align="center" background="image/listbg.gif" bgcolor="#FFFFFF" class="wuse12"><input name="chkAll" type="checkbox" id="chkAll" onclick="CheckAll(this.form)" value="checkbox" style="border:0" /></td>
    <td width="6%" height="22" align="center" background="image/listbg.gif" bgcolor="#FFFFFF" class="wuse12"> 广告ID</td>
    <td width="5%" align="center" background="image/listbg.gif" bgcolor="#FFFFFF" class="wuse12">排序</td>
    <td width="12%" align="center" background="image/listbg.gif" bgcolor="#FFFFFF" class="wuse12">显示方式</td>
    <td width="18%" align="center" background="image/listbg.gif" bgcolor="#FFFFFF" class="wuse12">显示位置</td>
    <td background="image/listbg.gif" bgcolor="#FFFFFF" class="wuse12">广告显示说明</td>
    <td width="11%" align="center" background="image/listbg.gif" bgcolor="#FFFFFF" class="wuse12">JS调用</td>
    <td width="11%" align="center" background="image/listbg.gif" bgcolor="#FFFFFF" class="wuse12">管　　理</td>
  </tr>
  <asp:Repeater ID="data_gg" runat="server">
    <ItemTemplate>
      <tr onmouseover="this.bgColor='#DBDBDB';" onmouseout="this.bgColor='#ffffff';" bgcolor="#ffffff" >
        <td height="30" class="wuse12"><input name="gg_int_id" type="checkbox" id="cp_int_id" value="<%#Eval("gg_id")%>" /></td>
        <td height="25" align="center" class="wuse12"><%#Eval("gg_id")%></td>
        <td align="center" class="wuse12"><%#Eval("gg_px")%></td>
        <td align="center" class="wuse12"><%#Eval("gg_fs")%></td>
        <td align="center" class="wuse12"><a href="#" onmouseover="wsug(event, '<%# Eval("gg_fs").replace("photo", "<img src=" & Eval("gg_page") & " width=150 />")%>')" onmouseout="wsug(event, 0)"><%#Eval("gg_wz")%></a> </td>
        <td class="wuse12" ><%#Eval("gg_sm")%></td>
        <td align="center" class="wuse12"><a href="javascript:copyToClipBoard('&lt;script src=&quot;http://<%=Request.Url.Authority & ubb.url%>web_js/web_guanguao.aspx?id=<%#Eval("gg_id")%>&amp;jsno=<%#Eval("gg_jsnumber")%> &quot; type=&quot;text/javascript&quot;&gt;&lt;/script&gt;');" >获取调用代码</a></td>
        <td align="center" class="wuse12"><%#Eval("gg_look").ToString.Replace("隐藏", "<span class=chense12>隐藏</span>")%>&nbsp;|&nbsp;<a href="?up_gg=True&amp;up_id=<%#Eval("gg_id")%>">修改</a></td>
      </tr>
    </ItemTemplate>
  </asp:Repeater>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td height="30"><span class="wuse12">
      <asp:Button CssClass="btn" ID="gg_quantity_notverify" runat="server" Text="批量显示"/>      
&nbsp;&nbsp;
<asp:Button CssClass="btn" ID="gg_quantity_verify" runat="server" Text="批量隐藏"/>
&nbsp;&nbsp;
<asp:Button CssClass="btn1_mouseout" ID="gg_quantity_delete" runat="server" Text="批量删除"/>
    </span></td>
  </tr>
</table>
</fieldset>
    </form>

	</body>
    </html>