<%@ page language="C#" autoeventwireup="true" inherits="Admin_Link_Operate, GroupTGWeb_deploy" %>

<%@ Register src="UserControl/MessageShow.ascx" tagname="MessageShow" tagprefix="ShopNum1" %>

<!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 runat="server">
    <link type="text/css" rel="Stylesheet" href="css/index.css" /> 
 <script type="text/javascript">
   
    //选择单图
   function openSingleChild()
    { 
        var k = window.showModalDialog("Image_List_Select.aspx",window,"dialogWidth:820px;status:no;dialogHeight:650px"); 
        if(k != null) 
        {
          var strLen=k.length;
          var lastIndex=k.lastIndexOf('/');
          document.getElementById("textBoxImgAddress").value = k.substring(lastIndex+1,strLen); 
         document.getElementById("ImageOriginalImge").src = k; 
        }
    } 
     </script>
   
    <style type="text/css">
        .style1
        {
            width: 320px;
        }
    </style>
   
</head>
<body style="padding:0; background-image: url(images/Bg_right.gif); background-repeat:repeat;font-size:12px">
    <form id="form1" runat="server">
    <div class="navigator"><asp:Label ID="LabelPageTitle" runat="server" Text="【 新增友情链接  】"></asp:Label></div>
 
        <table cellpadding="0" cellspacing="0" border="0" style="width:100%">
 
            <tr>
                <td width="20%">
                    &nbsp;</td>
                <td >
                    &nbsp;</td>
            </tr>
            <tr>
                <td align="right" >
             <asp:Label ID="lblLinkType" runat="server" Text="链接类型："></asp:Label>
                </td>
                <td align="left" >
        <asp:DropDownList ID="DropListLINKTYPE" runat="server" AutoPostBack="True" 
           CssClass="select2" onselectedindexchanged="DropListLINKTYPE_SelectedIndexChanged">
        </asp:DropDownList>
        <asp:Label ID="Label1" runat="server" ForeColor="#FF0066" Text="*"></asp:Label>
                </td>
            </tr>
            <tr>
                <td align="right"  >
    
        <asp:Label ID="lblTitle" runat="server">链接名称：</asp:Label>
                </td>
                <td align="left" >
        <asp:TextBox ID="textBoxTitle" runat="server" CssClass="input2"></asp:TextBox>
    
        <asp:Label ID="Label2" runat="server" ForeColor="#FF0066" Text="*"></asp:Label>
    
        <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" 
            ControlToValidate="textBoxTitle" ErrorMessage="不能为空"></asp:RequiredFieldValidator>
    
                    <asp:RegularExpressionValidator ID="RegularExpressionValidatorT" 
                        runat="server" ControlToValidate="textBoxTitle" Display="Dynamic" 
                        ErrorMessage="标题最多50个字符" ValidationExpression="^[\s\S]{0,50}$"></asp:RegularExpressionValidator>
    
                </td>
            </tr>
            <tr>
                <td align="right">
    
        <asp:Label ID="lblLinkAddress" runat="server" Text="链接地址："></asp:Label>
                </td>
                <td align="left" >
        <asp:TextBox ID="textBoxLinkAddress" runat="server" CssClass="input2">http://</asp:TextBox>
        <asp:Label ID="Label3" runat="server" ForeColor="#FF0066" Text="*"></asp:Label>
    
        <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" 
            ControlToValidate="textBoxLinkAddress" ErrorMessage="不能为空"></asp:RequiredFieldValidator>
    
                </td>
            </tr>
            <tr>
                <td align="right">
    
        <asp:Label ID="lblOrderID" runat="server" Text="排序号："></asp:Label>
                </td>
                <td align="left" >
                    <asp:TextBox ID="textBoxOrderID" runat="server" CssClass="input2"></asp:TextBox>
        <asp:Label ID="Label6" runat="server" ForeColor="#FF0066" Text="*"></asp:Label>
    
        <asp:RequiredFieldValidator ID="RequiredFieldValidatorOrderID" runat="server" 
            ControlToValidate="textBoxOrderID" ErrorMessage="不能为空"></asp:RequiredFieldValidator>
    
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" 
            ControlToValidate="textBoxOrderID" ErrorMessage="只能为数字" 
            ValidationExpression="^[0-9]*$"></asp:RegularExpressionValidator>
    
                </td>
            </tr>
            <tr><td colspan="2">
            <asp:Panel runat="server" ID="PanelImages" Visible="false">
            <table  cellpadding="0" cellspacing="0" border="0" style="width:100%">
            <tr>
                <td align="right">
    
        <asp:Label ID="lblIMGTYPE" runat="server" Text="图片类型："></asp:Label>
                </td>
                <td align="left" class="style1" >
                    <asp:RadioButtonList ID="radioButtonIMGTYPE" runat="server" 
            AutoPostBack="True" 
            onselectedindexchanged="radioButtonIMGTYPE_SelectedIndexChanged" 
            RepeatDirection="Horizontal" RepeatLayout="Flow">
            <asp:ListItem Selected="True" Value="0">本地图片</asp:ListItem>
            <asp:ListItem Value="1">远程图片</asp:ListItem>
        </asp:RadioButtonList>
    
                </td>
            </tr>
            <tr>
                <td align="right">
    
        <asp:Label ID="lblImgAddress" runat="server" Text="本地上传："></asp:Label>
                </td>
                <td align="left" class="style1" >
        <asp:TextBox ID="textBoxImgAddress" runat="server" 
            style="margin-right: 0px" CssClass="input2"></asp:TextBox>&nbsp;<asp:Label ID="Label10" runat="server" Text="*" ForeColor="red"></asp:Label>
                            <asp:Panel ID="Panelimage" runat="server">
                                <input id="ButtonSelectSingleImage" 
                    type="button" value="选择图片" onclick= "openSingleChild()"  /><img ID="ImageOriginalImge" 
                                    runat="server" alt="" src="" />
                    </asp:Panel>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidatorFreeLimit0" 
                            runat="server" ControlToValidate="textBoxImgAddress" Display="Dynamic" 
                            ErrorMessage="该值不能为空"></asp:RequiredFieldValidator>
                    <asp:RegularExpressionValidator ID="RegularExpressionValidatorPackImagePath" 
                        runat="server" ControlToValidate="textBoxImgAddress" Display="Dynamic" 
                        ErrorMessage="包装图纸路径最多250个字符" ValidationExpression="^[\s\S]{0,250}$"></asp:RegularExpressionValidator>
                     
                    &nbsp;<asp:RequiredFieldValidator ID="RequiredFieldValidatorImgAddress" runat="server" 
            ControlToValidate="textBoxImgAddress" ErrorMessage="不能为空"></asp:RequiredFieldValidator>
    
                </td>
            </tr>
         </table>
         </asp:Panel>
         </td></tr>
            <tr>
                <td align="right">
    
        <asp:Label ID="lblDescription" runat="server" Text="站点介绍："></asp:Label>
                </td>
                <td align="left" >
                    <asp:TextBox ID="textBoxDescription" runat="server" Height="60px" 
            TextMode="MultiLine" Width="298"></asp:TextBox>
    
                </td>
            </tr>
            <tr>
                <td align="right">
    
        <asp:Label ID="lblRemark" runat="server" Text="备注："></asp:Label>
                </td>
                <td align="left" >
        <asp:TextBox ID="textBoxMemo" runat="server" TextMode="MultiLine" 
                        Height="60px" Width="298"></asp:TextBox>
    
                </td>
            </tr>
            <tr>
                <td align="right">
    
        <asp:Label ID="lblIsShow" runat="server" Text="是否前台显示："></asp:Label>
                </td>
                <td align="left" >
                    <asp:CheckBox ID="CheckBoxIsShow" runat="server" Checked="True" Text="是" />
                </td>
            </tr>
            <tr>
                <td align="right">
    
                    &nbsp;</td>
                <td align="left" >
                    &nbsp;</td>
            </tr>
            <tr style="background-color:#EEEEEE;">
             <td align="right"></td>
                <td align="left" >
                     <div style="width:60%;margin:4px;">
        <asp:Button ID="BottonConfirm" runat="server" onclick="ButtonConfirm_Click" Text="确定" 
             CssClass="bt2"/>
                         <input ID="inputReset" runat="server"  type="reset" value="重置"  class="bt2"/>
                         
                         <a href="Link_Manage.aspx" ><img src="images/back.png" border="0" align="top" /></a>
                         
                         
                         
                         
                         <ShopNum1:MessageShow ID="MessageShow" runat="server" Visible="False" />
                     </div>
                </td>  
            </tr>
        </table>
  
 
    <asp:HiddenField ID="hiddenFieldGuid" runat="server" Value="0" />
    
    </form>
</body>
</html>
