
<!--#include file="top.asp"-->
<%
action=request.QueryString("action")%>
<head>
</head>

<body background="moban/3/images/bg.gif" topmargin="0">
<div align="center">
  <center>
  <table border="0" width="875" cellspacing="0" cellpadding="0" background="moban/3/images/body_bg1.gif" height="373">
  <tr><td width="100%" height="15"></td></tr>
    <tr>
      <td width="875" height="401" valign="top">
        <div align="center">
          <center>
          <table border="0" width="873" height="244" cellspacing="0" cellpadding="0">
            <tr>
              <td width="181" valign="top">
                <table border="0" width="179" height="195" cellspacing="0" cellpadding="0">
                  <tr>
                    <td width="100%" valign="top"><map name="FPMap3">
                      <area href="gbook.asp?id=<%=rs_shjia("shjiaid")%>" shape="rect" coords="31, 56, 90, 71">
                      <area href="book.asp?id=<%=rs_shjia("shjiaid")%>" shape="rect" coords="28, 81, 87, 97"></map><img border="0" src="moban/3/images/gbook.gif" usemap="#FPMap3"></td>
                  </tr>
                </table>
              </td>
              <td width="510" height="174" valign="top" align="center">
                <div align="center">
                  <center>
                  <table border="0" width="510" cellspacing="0" cellpadding="0" height="172">
                    <tr>
                      <td width="510" background="moban/3/images/top_top.gif" height="61">
                        <table border="0" width="100%" height="100%" cellspacing="0" cellpadding="0">
                          <tr>
                            <td width="100%">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
                          </tr>
                          <tr>
                            <td width="100%">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;     
                              <font color="#666666"><b>客户留言</b></font></td>
                          </tr>
                        </table>
                      </td>
                    </tr>
                    <tr>
                      <td width="100%" background="moban/3/images/linemid.gif" height="400" valign="top" align="center">
                        <div align="center">
                          <center>
                          <table border="0" width="96%">
                            <tr>
                              <td width="100%" valign="top"><%select case action
case ""
%>
<table width="479" border="1" align="center" cellpadding="1" cellspacing="1" bordercolorlight="#FFFFFF" bordercolordark="#E1E1E1">
<form name="fkinfo" method="post" action="gbook.asp?id=<%=rs_shjia("shjiaid")%>&action=save">
<tr> 
<td height="30" colspan="3" align="center" bgcolor="#F4F4F4" width="469"><span class="style1">尊敬的客户，请在这里将您们的宝贵建议反馈给</span><font color="#999999"><font color="#FF0000"><%=rs_shjia("name")%></font></font><span class="style1">，谢谢 ！</span></td>
</tr>
<tr> 
<td width="70" rowspan="5" align="left"><div align="right"><img border="0" src="moban/1/images/gbook.gif"></div></td>
<td width="76"></td>
<td width="311"> 
<input name="shjiaid" type="hidden" value="<%=rs_shjia("shjiaid")%>"> 
</td>
</tr>
<tr> 
<td align="right" width="76">类　型：</td>
<td width="302" style="padding-left: 10px"> 
<select class="wenbenkuang" name="fkleixing" id="fkleixing">
<option value="简单的留言" selected>简单的留言</option>
<option value="对网站的意见">对网站的意见</option>
<option value="对公司的建议">对公司的建议</option>
<option value="具有合作意向">具有合作意向</option>
<option value="产品投诉">产品投诉</option>
<option value="服务投诉">服务投诉</option>
</select></td>
</tr>
<tr> 
<td align="right" width="76">姓　名：</td>
<td width="302" style="padding-left: 10px">
<input class="wenbenkuang" name="fkusername" type="text" id="fkusername" size="20"> 
</td>
</tr>
<tr> 
<td align="right" width="76">e-mail：</td>
<td width="302" style="padding-left: 10px">
<input class="wenbenkuang" name="fkemail" type="text" id="fkemail" size="40"> 
</td>
</tr>
<tr> 
<td align="right" width="76">地　址：</td>
<td width="302" style="padding-left: 10px">
<input class="wenbenkuang" name="fklaizi" type="text" id="fklaizi" size="40"></td>
</tr>
<tr> 
<td colspan="2" align="right" width="152">电　话：</td>
<td width="302" style="padding-left: 10px">
<input class="wenbenkuang" name="fktel" type="text" id="fktel" size="20"> 
</td>
</tr>
<tr> 
<td colspan="2" align="right" width="152">主　题：</td>
<td width="302" style="padding-left: 10px">
<input class="wenbenkuang" name="fksubject" type="text" id="fksubject" size="40"> 
</td>
</tr>
<tr> 
<td colspan="2" align="right" width="152">信　息：</td>
<td width="302" style="padding-left: 10px">
<textarea class="wenbenkuang" name="fkcontent" cols="40" rows="5" id="fkcontent"></textarea> 
</td>
</tr>
<tr> 
<td colspan="2" align="right" width="152"></td>
<td width="302" style="padding-left: 10px">
<input class="go-wenbenkuang" name="submit" value=提交信息 type=submit onClick="return checkfk();">
[请注意适当使用<font color="#FF0000">Enter</font>键来换行]                                    
</td>
</tr>
</form>
</table>
                              </td>
                            </tr>
                          </table>
                          </center>
                        </div>
                      </td>
                    </tr>
                    <tr>
                      <td width="100%" height="12" background="moban/3/images/linedi.gif"><img border="0" src="moban/3/images/linedi.gif"></td>
                    </tr>
                  </table>
                  </center>
                </div>
              </td>
              <td width="185" valign="top" align="center">
                <div align="center">
                  <center>
                  <table border="0" width="163" background="moban/3/images/right.gif" height="334" cellspacing="0" cellpadding="0">
                    <tr>
                      <td width="100%" valign="top">
                        <table border="0" width="100%" cellspacing="0" cellpadding="0" height="230">
                          <tr>
                            <td width="100%" height="56">&nbsp; 
                            </td>
                          </tr>
                          <tr>
                            <td width="100%" height="9" align="center"><%=rs_shjia("tel")%> 
                            </td>
                          </tr>
                          <tr>
                            <td width="100%" height="27">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
                            </td>
                          </tr>
                          <tr>
                            <td width="100%" height="19" valign="top" align="center"><a href=mailto:<%=rs_shjia("UserEmail")%>><%=right(rs_shjia("UserEmail"),18)%> </a> 
                            </td>
                          </tr>
                          <tr>
                            <td width="100%" height="31">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
                          </tr>
                          <tr>
                            <td width="100%" height="38" valign="top">
                              <table border="0" width="100%" height="43">
                                <tr>
                                  <td width="28%" height="39"></td>
                                  <td width="67%" valign="top" height="39"> <%=rs_shjia("dz")%></td>
                                  <td width="6%" height="39"></td>
                                </tr>
                              </table>
 
                            </td>
                          </tr>
                          <tr>
                            <td width="100%" height="49" valign="top">
                              <table border="0" width="100%" height="37">
                                <tr>
                                  <td width="100%" height="25">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
                                  </td>
                                </tr>
                                <tr>
                                  <td width="100%" height="21">
                                    <table border="0" width="100%">
                                      <tr>
                                        <td width="36%"></td>
                                        <td width="64%" valign="bottom"><b><a href="gbook.asp?id=<%=rs_shjia("shjiaid")%>"><font color="#636363">在线留言</font></a></b></td>
                                      </tr>
                                    </table>
                                  </td>
                                </tr>
                              </table>
                            </td>
                          </tr>
                          <tr>
                            <td width="100%" height="18"></td>
                          </tr>
                          <tr>
                            <td width="100%" height="18"></td>
                          </tr>
                        </table>
                      </td>
                    </tr>
                  </table>
                  </center>
                </div>
              </td>
            </tr>
          </table>
          </center>
        </div>
      </td>
    </tr>
  </table>
  </center>
</div>
<!--#include file="copyright.asp"-->
<%
	case "save"
	if session("fkfk")=minute(now) then
	response.write "<script language=javascript>alert('对不起，您不可以重复提交信息，请稍后再试！');history.go(-1);</script>"
	response.End
	end if
	function HTMLEncode2(fString)
	fString = Replace(fString, CHR(13), "")
	fString = Replace(fString, CHR(10) & CHR(10), "</P><P>")
	fString = Replace(fString, CHR(10), "<BR>")
	HTMLEncode2 = fString
	end function
set rs=server.CreateObject("adodb.recordset")
rs.open "select * from shop_shjiafk",conn,1,3
rs.addnew
rs("shjiaid")=trim(request("shjiaid"))
rs("fkleixing")=request("fkleixing")
rs("fksubject")=trim(request("fksubject"))
rs("fkcontent")=htmlencode2(trim(request("fkcontent")))
rs("fkusername")=trim(request("fkusername"))
rs("fkemail")=trim(request("fkemail"))
rs("fktel")=trim(request("fktel"))
rs("fklaizi")=trim(request("fklaizi"))
rs("fkdate")=now
rs("fkip")=Request.ServerVariables("remote_addr")
rs.update
rs.close
set rs=nothing
response.write "<script>alert('您的留言已成功提交，感谢您的参与！');window.location.href='gbook.asp?id="&id&"';</script>"
session("fkfk")=minute(now)
end select%>
<SCRIPT LANGUAGE="JavaScript">
<!--
function checkspace(checkstr) {
  var str = '';
  for(i = 0; i < checkstr.length; i++) {
    str = str + ' ';
  }
  return (str == checkstr);
}

function checkfk()
{
   if(checkspace(document.fkinfo.fksubject.value)) {
	document.fkinfo.fksubject.focus();
    alert("您没有填写主题！");
	return false;
  }
   if(checkspace(document.fkinfo.fkusername.value)) {
	document.fkinfo.fkusername.focus();
    alert("请填写您的姓名！");
	return false;
  }
   if(checkspace(document.fkinfo.fklaizi.value)) {
	document.fkinfo.fklaizi.focus();
    alert("请填写您来自哪里！");
	return false;
  }
     if(checkspace(document.fkinfo.fkcontent.value)) {
	document.fkinfo.fkcontent.focus();
    alert("请填写反馈信息内容！");
	return false;
  }
  
  if(document.fkinfo.fkemail.value.length!=0)
  {
    if (document.fkinfo.fkemail.value.charAt(0)=="." ||        
         document.fkinfo.fkemail.value.charAt(0)=="@"||       
         document.fkinfo.fkemail.value.indexOf('@', 0) == -1 || 
         document.fkinfo.fkemail.value.indexOf('.', 0) == -1 || 
         document.fkinfo.fkemail.value.lastIndexOf("@")==document.fkinfo.fkemail.value.length-1 || 
         document.fkinfo.fkemail.value.lastIndexOf(".")==document.fkinfo.fkemail.value.length-1)
     {
      alert("Email地址格式不正确！");
      document.fkinfo.fkemail.focus();
      return false;
      }
   }
 else
  {
   alert("Email不能为空！");
   document.fkinfo.fkemail.focus();
   return false;
   }

}
//-->
</script> 
</body>

