<!--#include file="fstop.asp"-->
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">


<title>添加新商盟--<%=title%></title>
<script language="JavaScript" src="afoxdmin/calendar.js"></script>
<script language = "JavaScript">
function checkpro()
{
    if(checkspace(document.myform.name.value)) {
	document.myform.name.focus();
    alert("请输入商盟名称！");
	return false;
  }

     if(checkspace(document.myform.code.value)) {
	document.myform.code.focus();
    alert("请输入联系人！");
	return false;
  }
     if(checkspace(document.myform.telll.value)) {
	document.myform.telll.focus();
    alert("请输入联系电话！");
	return false;
  }
      if(checkspace(document.myform.pweight.value)) {
	document.myform.pweight.focus();
    alert("请输入商盟地址！");
	return false;
  }
 
}
function checkspace(checkstr) {
  var str = '';
  for(i = 0; i < checkstr.length; i++) {
    str = str + ' ';
  }
  return (str == checkstr);
}
	function regInput(obj, reg, inputStr)
	{
		var docSel	= document.selection.createRange()
		if (docSel.parentElement().tagName != "INPUT")	return false
		oSel = docSel.duplicate()
		oSel.text = ""
		var srcRange	= obj.createTextRange()
		oSel.setEndPoint("StartToStart", srcRange)
		var str = oSel.text + inputStr + srcRange.text.substr(oSel.text.length)
		return reg.test(str)
	}
//-->
</script>

<div align="center">

<table width="930" border="0" cellspacing="1"> 
<tr> 
  <td height="24" align="center" bgcolor="#9CD6F1" width="7">　</td>
  <td height="24" align="center" bgcolor="#9CD6F1" width="750">
	<p align="left"><b><img border="0" src="images/z1.gif" width="50" height="18"> 您的位置  
			<font color="#FFFFFF">-></font> <a class="scap1" href="index.htm"><%=title%></a>
			<font color="#FFFFFF">-></font> 添加百业联盟（<font color="#FF0000">注意：仅限山西地区</font>）</b></td>
</tr> 
<tr>  
<form name="myform" method="post" action="savesj.asp">
	
<td bgcolor="#FFFFFF" colspan="2"> 
  <div align="center">
  <table width="930" border="2" cellspacing="1" bordercolor="#FFFFFF" bgcolor="#F2F2F2" class="table2">
          <tr> 
            <td align="right" bgcolor="#f4f4f4" rowspan="14"><!--#include file="shanghelp.asp"--></td>
            <td width="12%" align="right" background="images/topbg.gif" bgcolor="#f4f4f4"><strong>选择分类： </strong></td>
            <td width="54%" bgcolor="#FFFFFF"> 
			<select name="categoryid">  
<%
sort(0)
dim ii
ii=0
sub sort(selec)
	sql="select * from FOX_category where ParentID = "&selec&" order by categoryorder"
	Set Rs1=Conn.Execute(sql)
	do while not rs1.eof
if selec=0 then
%>
<option value="<%=int(rs1("categoryid"))%>"><%=rs1("category")%></option>
<%
else
%>
<option value="<%=int(rs1("categoryid"))%>"><%=string(ii*2,"　")%><%=rs1("category")%></option>
<%
end if
ii=ii+1
	sort rs1("categoryid")
ii=ii-1
	rs1.movenext
	loop
rs1.close
Set Rs1 = Nothing
end sub

%>
		</select>           <font color="#FF0000">* 尽量选下级，容易被查找</font></td>
          </tr>
          <tr>
            <td align="right" background="images/topbg.gif" bgcolor="#f4f4f4"><strong>商盟名称： </strong></td>
            <td bgcolor="#FFFFFF"><input name="name" type="text" class="input_sr" id="name" size="30" />
			<font color="#FF0000">*</font></td>
          </tr>

          <tr> 
            <td align="right" background="images/topbg.gif" bgcolor="#f4f4f4">
			<strong>商盟类型： </strong></td>
            <td bgcolor="#FFFFFF"> 
			<input name="mark" type="hidden" class="input_sr" id="mark" size="12" value="免费会员" >
			<font color="#FF0000">免费会员</font>
              </td>
          </tr>
          <tr> 
            <td align="right" background="images/topbg.gif" bgcolor="#f4f4f4">
			<strong>联系人：            </strong></td>
            <td bgcolor="#FFFFFF"> <input name="code" type="text" class="input_sr" id="code" size="30">
			<font color="#FF0000">*</font></td>
          </tr>          
          <tr>
            <td align="right" background="images/topbg.gif" bgcolor="#f4f4f4">
			<strong>联系电话：</strong></td>
            <td bgcolor="#FFFFFF">
			<input name="telll" type="text" class="input_sr" id="telll" size="30"><font color="#FF0000"> 
			*</font></td>
          </tr>
          <tr>
            <td align="right" background="images/topbg.gif" bgcolor="#f4f4f4">
			<strong>营业时间：</strong></td>
            <td bgcolor="#FFFFFF">
			<input name="waitime" type="text" class="input_sr" id="waitime" size="30">
			<font color="#FF0000">*</font></td>
          </tr>
          <tr>
            <td align="right" background="images/topbg.gif" bgcolor="#f4f4f4">
			<strong>导购路线：</strong></td>
            <td bgcolor="#FFFFFF">
			<input name="luuu" type="text" class="input_sr" id="luuu" size="30">
			<font color="#FF0000">* 公交路线</font></td>
          </tr>
          <tr>
            <td align="right" background="images/topbg.gif" bgcolor="#f4f4f4">
			<b>所属地区：</b></td>
            <td bgcolor="#FFFFFF">
			<%
dim rsclass
dim sqlclass
dim count
set rsclass=server.createobject("adodb.recordset")
sqlclass = "select * from FOX_shi order by paixu desc"
rsclass.open sqlclass,conn,1,1
%><SCRIPT language = "JavaScript">
var onecount;
onecount=0;
subcat = new Array();
        <%
        count = 0
        do while not rsclass.eof 
        %>
subcat[<%=count%>] = new Array("<%= trim(rsclass("shi"))%>","<%= trim(rsclass("sheng"))%>","<%= trim(rsclass("id"))%>");
        <%
        count = count + 1
        rsclass.movenext
        loop
        rsclass.close
        %>
onecount=<%=count%>;

function changelocation(locationid)
    {
    document.myform.shi.length = 0; 

    var locationid=locationid;
    var i;
    for (i=0;i < onecount; i++)
        {
            if (subcat[i][1] == locationid)
            { 
                document.myform.shi.options[document.myform.shi.length] = new Option(subcat[i][0], subcat[i][2]);
            }        
        }
        
    }    
                      </SCRIPT><%
sqlclass = "select * from FOX_sheng order by paixu desc"
rsclass.open sqlclass,conn,1,1
if rsclass.eof and rsclass.bof then
response.write "请先添加栏目。"
response.end
else
%><SELECT name="sheng" onChange="changelocation(document.myform.sheng.options[document.myform.sheng.selectedIndex].value)" size="1" class="right_bg01">
<OPTION selected value="0">==分类==</OPTION>
                                <%do while not rsclass.eof
%>
                                <OPTION value="<%=trim(rsclass("id"))%>"><%=trim(rsclass("sheng"))%></OPTION>
                                <%
        rsclass.movenext
        loop
	    end if
        rsclass.close
        set rsclass=nothing
%>
                              </SELECT>
                              <SELECT name="shi" size="1" class="right_bg01">
                                <OPTION selected value="0">==二级分类==</OPTION>
                              </SELECT> （<font color="#FF0000">原则仅收录山西商家，外地不显示</font>）</td>
          </tr>
          <tr>
            <td align="right" background="images/topbg.gif" bgcolor="#f4f4f4">
			<strong>商盟地址： </strong></td>
            <td bgcolor="#FFFFFF">
			<input name="pweight" type="text" class="input_sr" id="pweight" size="49" />
			<font color="#FF0000">*</font></td>
          </tr>
          <tr>
            <td height="9" align="right" background="images/topbg.gif" bgcolor="#f4f4f4">
			<strong>备注：</strong></td>
            <td bgcolor="#FFFFFF">
			<input name="beizhu" type="text" class="input_sr" id="beizhu" size="49" />
			<font color="#FF0000">*（20字）</font></td>
          </tr>
          <tr>
            <td height="9" align="right" background="images/topbg.gif" bgcolor="#f4f4f4">
			<strong>折扣比率：</strong></td>
            <td bgcolor="#FFFFFF">
			<INPUT NAME="vipprice" TYPE="text" class="input_sr" ID="vipprice" value="0" SIZE="1">　折
			（<font color="#FF0000">0为不打折，1－9为打折</font>）</td>
          </tr>
          <tr> 
            <td align="right" valign="top" bgcolor="#f4f4f4"><strong>详细简介：</strong></td>
            <td bgcolor="#FFFFFF"> 　</td>
          </tr>

          <tr> 
            <td align="right" valign="top" bgcolor="#f4f4f4" colspan="2">
			<INPUT type="hidden" name="detail" value=""><iframe ID="detail" src="../scgjb/ewebeditor.asp?id=detail&style=s_mini" frameborder="0" scrolling="no" width="530" HEIGHT="269"></iframe>            </td>
          </tr>

          <tr>
            <td height="25" align="right" bgcolor="#f4f4f4"><strong>商盟类别：</strong></td>
            <td bgcolor="#FFFFFF"><input name="recommend" type="radio" value="0" checked="checked" /> 
			免费（更好展示，选择收费！请联系<%=tel%><font color="#FF0000">拍照</font>）<hr size="0" />
                <input name="Submit2" type="submit" class="input_bot" onclick="return checkpro();" value="确认以上修改" />               </td>
          </tr>
</table>
  </div>
  <br></td></form></tr> </table></div>
  <!--#include file="ffbottom.asp"--></body></html>