<%@ Page Language="C#" MasterPageFile="~/member/UserManage.master" AutoEventWireup="true"
    CodeFile="LinkAdd.aspx.cs" Inherits="member_Link_LinkAdd" Title="Untitled Page" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContInfo" runat="Server">
  <div id="sub_content">
    <div class="pagetitle"> 友情连接管理</div>
	<div class="tishi">
            <span>提&nbsp;示：</span>·上传网站logo尽量用标准尺寸88*35大小图片！
			</div>
    <div class="h2_title">
        <h2>添加友情链接</h2>
    </div>
      <table cellspacing="0" cellpadding="0" border="0" runat="server" class="lr_bo">
        <tr>
          <td width="16%" class="thing"> 链接标题： </td>
          <td class="td_c"><asp:TextBox ID="txtName" runat="server" Width="200px"></asp:TextBox>
          </td>
        </tr>
        <tr>
          <td  class="thing"> 链接地址： </td>
          <td class="td_c"><asp:TextBox ID="txtUrl" runat="server" Width="200px"></asp:TextBox>
          </td>
        </tr>
        <tr>
          <td class="thing"> 网站Logo： </td>
          <td class="td_c"><asp:HiddenField ID="ImgUrl1" runat="server" />
              <a href="" id="txturldz" target="_blank"> <img border="0" src="../../Images/System/wutu.gif" id="ImgUrl" alt="" runat="server"
                        style="width: 106px; height: 95px" /></a><br />
              <input name="button" type="button" id="txtupload" onclick="return rowTest()" value="上传" />
            <br />
              <div id="rowTest" style="display: none">
                <iframe name="tag" src="../Tool/Upload.html" style="width: 550px; height: 190px"
                        frameborder="0" scrolling="no" onload="this.height=tag.document.body.scrollHeight"> </iframe>
              </div></td>
        </tr>
        <tr>
          <td align="center" colspan="2" height="40"><asp:Button ID="btnSave" runat="server" Text="保存" OnClick="btnSave_Click"  CssClass="i_button" />
              <asp:Button ID="btnBack" runat="server" Text="返回" OnClick="btnBack_Click" CssClass="i_button"/>  
          </td>
        </tr>
      </table>
    </div>
    <script type="text/javascript" src="../../JS/Common.js"> </script>
    <script type="text/javascript">
    $("ctl00_ContInfo_btnSave").onclick=function()
    {
    if( $("ctl00_ContInfo_txtName").value.replace(/\s/g,'')=="")
      {
      alert( "链接标题不能为空!")
      $("ctl00_ContInfo_txtName").focus();
      return false;
      }
     if($("ctl00_ContInfo_txtUrl").value.replace(/\s/g,'')=="")
      {
         alert("链接地址不能为空!")
         $("ctl00_ContInfo_txtUrl").focus();
         return false
      }
      if(FileUPload(2)!=0)
      {
        alert("图片上传不能空!");
        return false;
      }
     
    }
    </script>
  </div>
</asp:Content>
