<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<% data_path="../" 'ACC连接数据库路径，对SQL无效 %>
<!--#include file="../conn/conn.asp"-->
<!--#include file="../inc/safe.asp"-->
<!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=gb2312" />
<title></title>
<style type="text/css">
<!--
*{margin:0; padding:0;}
#top1 ul{list-style:none;}
#top1{width:85%; height:70px; border:1px solid #FFCB99; background-color:#FFF8EE; margin:2px 0px 15px 16px; padding:10px;}
.STYLE1 {
	font-size: 16px;
	font-weight: bold;
}
body,td,th {
	font-size: 12px;
}
.STYLE5 {color: #FF5400}
.STYLE6 {color: #663300}
.STYLE7 {color: #112482}
-->
</style>
</head>
<%
if issession=0 then
if request.Cookies("Yxmemberid")="" then
response.write "<script language='javascript'>"
response.write"parent.location.href='../login/login1.asp';</SCRIPT>"
response.end
end if
username=Replace_Text(request.Cookies("Yxmember"))
gsid=Replace_Text(request.Cookies("Yxmemberid"))
else
if session("id")="" then
response.write "<script language='javascript'>"
response.write"parent.location.href='../login/login1.asp';</SCRIPT>"
response.end
end if
username=session("user")
gsid=session("id")
end if

if request("action")="chk" then
  call userchk()
end if

sub userchk()
	username1=trim(request("buname"))
	if username1="" then
		response.Write("<script language='javascript'>alert('请输入用户名！');history.go(-1);</script>")
		response.End
	elseif username1=username then
		response.Write("<script language='javascript'>alert('不能对自己发起订单！');history.go(-1);</script>")
		response.End
	else
		set rs=server.CreateObject("adodb.recordset")
		sql="select id,[user] from yixiang_corporation where [user]='"&username1&"'"
		rs.open sql,conn,1,1
		if rs.eof then
			response.Write("<script language='javascript'>alert('对不起，该用户不存在！');history.go(-1);</script>")
			response.End
		else
			response.Redirect"fq_order_s.asp?id="&rs("id")
		end if
		rs.close
		set rs=nothing
	end if
end sub
%>
<body>
<table width="100%" border="0" cellpadding="0" cellspacing="0" style="margin:25px 0 0 0;">
  <tr>
    <td height="auto" valign="top">
	<h3><span>&nbsp;&nbsp;<span class="STYLE7">发起订单</span></span></h3>
	<div id="top1">
	  <ul>
	    <li class="STYLE1"><font color="#FF5400">注意：订单发给谁？</font></li>
		<li style="background:url(../images/icon1.gif) no-repeat; height:50px; padding:10px 0 0 50px;">
		  <table width="84%" height="69" border="0" cellpadding="0" cellspacing="0">
            <tr>
              <td height="26">目前只有卖家才可以发起订单！买家必须为<%=WebName%>网站注册会员！
</td>
            </tr>
            <tr>
              <td height="19">&nbsp;为了确保您的订单是有效的，请务必与买家确认后，再使用该功能给您的买家发起订单。</td>
            </tr>
            <tr>
              <td height="24">&nbsp;&nbsp;如未经过买家同意就发送订单，引起的投诉将由卖家负责&nbsp;。</td>
            </tr>
          </table>
		</li>
	  </ul>
	</div>	</td>
  </tr>
  <tr>
    <td height="25"><h3><span>&nbsp;&nbsp;<span class="STYLE6">①选择买家</span></span><span>&nbsp;&nbsp;②确认买家信息&nbsp;&nbsp;③填写订单信息</span></h3></td>
  </tr>
  <tr>
    <td><form id="form1" name="form1" method="post" action="?action=chk">
	&nbsp;&nbsp;
	<table width="80%" border="0" cellpadding="0" cellspacing="0">
      <tr>
        <td width="21%" height="25" align="center" bgcolor="#F6F6F6" style="border-bottom:1px solid #F6F6F6;">买家会员名：</td>
        <td width="79%" height="25" style="border-bottom:1px solid #F6F6F6;"><label>
          <input name="buname" type="text" id="buname" />
          <span class="STYLE5">注：必须为注册会员</span>        </label></td>
      </tr>
      <tr>
        <td height="25">&nbsp;</td>
        <td height="25"><label>
          <input type="submit" name="Submit" value="下一步" />
        </label></td>
      </tr>
    </table>
    </form>    </td>
  </tr>
  <tr>
    <td height="25" style="padding:10px 0 0 0;">&nbsp;&nbsp;&nbsp;<span class="STYLE5">温馨提示</span>：请确保您与所选买家已经沟通,如果没有，请慎重操作。</td>
  </tr>
</table>
</body>
</html>
