日期:2014-05-17  浏览次数:20422 次

看到有帖子说关于多条件筛选,类似京东商城的,我写了个,欢迎拍砖
我最近刚好项目要用到,我也觉得还是用Url传参的形式比较合理,可以增加搜索引擎收入,我感觉没有说的那么复杂。
看实例
HTML code
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="test.aspx.cs" Inherits="Plus.test" %>

<!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 runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
<div class="getLine"><strong>厂家数量:</strong>

<ul id="cjsl">

<li><a href="" target="_self"><span class="aSpan">全部</span></a><span class="rightborder">&nbsp;</span></li>

<li><a href="?j=1&z=<%=RequestS("z") %>&s=<%=RequestS("s") %>" target="_self">独家</a></li>

<li><a href="?j=2&z=<%=RequestS("z") %>&s=<%=RequestS("s") %>" target="_self">2家</a></li>

<li><a href="?j=3&z=<%=RequestS("z") %>&s=<%=RequestS("s") %>" target="_self">3家</a></li>

<li><a href="?j=4&z=<%=RequestS("z") %>&s=<%=RequestS("s") %>" target="_self">4-10家</a></li>

<li><a href="?j=5&z=<%=RequestS("z") %>&s=<%=RequestS("s") %>" target="_self">10家以上</a></li>

</ul>

<div class="clear"></div>

</div>

<div class="getLine">

<strong>质量层次:</strong>

<ul id="zlcc">

<li><a href="" target="_self"><span class="aSpan">全部</span></a><span class="rightborder">&nbsp;</span></li>

<li><a href="?j=<%=RequestS("j") %>&z=1&s=<%=RequestS("s") %>" target="_self">GMP</a></li>

<li><a href="?j=<%=RequestS("j") %>&z=2&s=<%=RequestS("s") %>" target="_self">单独定价</a></li>

<li><a href="?j=<%=RequestS("j") %>&z=3&s=<%=RequestS("s") %>" target="_self">优质优价</a></li>

<li><a href="?j=<%=RequestS("j") %>&z=4&s=<%=RequestS("s") %>" target="_self">原研专利</a></li>

</ul>

<div class="clear"></div>

<div class="getLine"><strong>上市时间:</strong>

<ul id="sssj">

<li><a href="" target="_self"><span class="aSpan">全部</span></a><span class="rightborder">&nbsp;</span></li>

<li><a href="?j=<%=RequestS("j") %>&z=<%=RequestS("z") %>&s=1"   class="<%=RequestS("s")=="1"?"hover":""%>"  target="_self">2010年</a></li>

<li><a href="?j=<%=RequestS("j") %>&z=<%=RequestS("z") %>&s=2" target="_self">2009年</a></li>

<li><a href="?j=<%=RequestS("j") %>&z=<%=RequestS("z") %>&s=3" target="_self