我想在搜索页面的url中添加一个复选框值,并从get复选框值中搜索新查询

时间:2014-04-10 12:04:26

标签: javascript php jquery ajax

<div class="city-list">
                    <ul>
                        <li><input name="Bhk" type="checkbox" value="All" onClick="self.location=location.href+'?Bhk=All'" <?php if($_GET['Bhk'] == 'All') { echo "checked='checked'"; } ?>/>All </li>
                        <li><input name="Bhk" type="checkbox" value="1 BHK" onClick="self.location=location.href+'?Bhk=1 BHK'"/>1 BHK </li>
                        <li><input name="Bhk" type="checkbox" value="2 BHK" onClick="self.location=location.href+'?Bhk=2 BHK'"/>2 BHK </li>
                        <li><input name="Bhk" type="checkbox" value="3 BHK" onClick="self.location=location.href+'?Bhk=3 BHK'"/>3 BHK   </li>
                        <li><input name="Bhk" type="checkbox" value="4 BHK" onClick="self.location=location.href+'?Bhk=4 BHK'"/>4 BHK   </li>
                        <li><input name="Bhk" type="checkbox" value="5 BHK" onClick="self.location=location.href+'?Bhk=5 BHK'"/>5 BHK  </li>




                    </ul>
                </div>

我的网址是:http://www.successghar.com/search-result.php?ResidentalType=Sell&ResidentialProperties=Apartment&Bhk=&budget_from=&budget_to=&City=Ahmedabad+West&ResidentalPropertySubmit=GO

我想要当我选中任何复选框时,此值自动广告在Bhk = 1 Bhk,2 Bhk这样可能并优化新查询

0 个答案:

没有答案