<%@ page language="C#" masterpagefile="~/MasterPage.master" autoeventwireup="true" inherits="feedback, App_Web_m8jzsuiw" title="" enableviewstatemac="false" enableEventValidation="false" viewStateEncryptionMode="Never" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">


<div class="banner-ny">
	<img src="images/banner4.jpg" width="1000" height="218" />
</div>

<div class="ny-main">
	<div class="main-txt">
		<div class="bg-fff">
			<div class="main-left">
				<h3>在线咨询</h3>
				<div class="category">
					<ul>
       
            <li id="left1"><a href="feedback.aspx">在线咨询</a></li>

						
					</ul>
				</div>
				<div class="contact-lib">

                   <!--#include file="left.htm"-->

				</div>
			</div>
			<div class="main-right">
				<h5 class="main-right-h5">您的位置：<a href="default.aspx">首页</a> > <a href="contact.aspx">在线咨询</a></h5>
				<div class="danye-detail">
	

       <asp:Repeater ID="RepeaterN" runat="server">
         <ItemTemplate>
         <table width="100%" cellpadding="5" cellspacing="0" style="margin-bottom:10px;"> 
         <tr>
           <td width="50" style="color:#0062B2; line-height:30px;" valign="top">问题：</td><td><%#Eval("content") %><br /><span style="color:#999;">留言时间：<%#Eval("addtime") %></span></td>
         </tr>                
         <tr>
           <td width="50" style="color:#ff0000; line-height:30px;" valign="top">回答：</td><td style="color:#ff0000;"><%#Eval("rcontent") %></td>
         </tr>
         </table>             
         </ItemTemplate>
      </asp:Repeater>				
      
		
		<div class="ppage" id="PageSpan" runat="server"></div>	 



		<div style="padding-left:100px; border-top:0px solid #ccc; padding-top:0px;">
                <table class="contactform">
                	<tr>
                	  <td colspan="2" style="text-align:center; font-family:'微软雅黑'; font-size:16px; padding:5px 0;">在线咨询</td>
                	</tr>
                	<tr>
                    	<td>* 称呼Name</td>
                        <td>邮箱Email</td>
                    </tr>
                	<tr>
                    	<td><input type="text" value="" name="lxr" id="lxr" /></td>
                        <td><input type="text" value="" name="email" id="email" /></td>
                    </tr>
                	<tr>
                    	<td>电话Tel</td>
                        <td>公司名称Company</td>
                    </tr>
                	<tr>
                    	<td><input type="text" value="" name="tel" id="tel" /></td>
                        <td><input type="text" value="" name="company" id="company" /></td>
                    </tr>
                	<tr>
                    	<td colspan="2">* 留言Message</td>
                    </tr>
                	<tr>
                    	<td colspan="2"><textarea class="liuyan" name="content" id="content"></textarea></td>
                    </tr>
                	<tr>
                    	<td colspan="2"><input type="button" value="提交 Submit" name="tijiao" id="tijiao" class="sub2"></td>
                    </tr>
                </table>		
		
		</div>






					
	
					
				</div>
			</div>
		</div>
	</div>
</div>


<script language="javascript">
$("#top5").addClass("curr");
$("#left1").addClass("curr");


$(function(){

    $("#tijiao").click(function(){
		 
    var lxr = $("#lxr").val(); 
    var content = $("#content").val(); 
    var email = $("#email").val();
    var tel = $("#tel").val();
    var company = $("#company").val();
    
    if(lxr.replace(/\ /g, "") == "") {
	    $("#lxr").focus();
        alert("您的称呼");
	    return false;
    }
  
    if(email.replace(/\ /g, "") == "") {
	   // $("#email").focus();
        //alert("您的电子邮箱");
	    //return false;
     }
  
    if (/^\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$/.test(email) == false) {
        //alert("邮箱格式不正确，请重新填写");
        //return false;
    }
    if(content.replace(/\ /g, "") == "") {
        $("#content").focus();
        alert("您的留言");
	    return false;
    } 
		
 			
		    $.post("feedback.aspx?action=add",{lxr:lxr,tel:tel,email:email,company:company,content:content},function(data){ 
			    if(data=="ok"){
			      alert("感谢您的留言，我们会及时回复");
			      window.location.href="default.aspx";
			    }else{
				    alert(data);
				    return false;
			    }
		    }) 					 
		  
	})	

})

</script> 

</asp:Content>

