Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!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">
- <body>
- <form id="form1" method="post" action= "">
- <div style="padding:20px">
- <select id="bedroom" multiple="multiple" name="bedroom[]">
- <option value="2bhk" selected="selected">2bhk</option>
- <option value="3bhk" >3bhk</option>
- </select>
- <select id="prop-type" multiple="multiple" name="ptype[]">
- <option value="residential" >Residential Apartments</option>
- <option value="commercial" >Commercial Apartments</option>
- </select>
- <script type="text/javascript">
- $(function() {
- $('select').multiselect({
- });
- $('#btnget').click(function() {
- alert($('#chkveg').val());
- })
- });
- </script>
- </div>
- <input type="submit" value="submit" name="submit"/>
- </form>
- </body>
- </html>
- <?php
- if(isset($_POST['submit'])) {
- $bedrooms = implode('',$_POST['bedroom']);
- $property = implode('-',$_POST['ptype']);
- $url = "search/".$bedrooms."-".$property."";
- header('Location: '.$url);
- }
- ?>
- <?php
- $url = $_SERVER['REQUEST_URI'];
- $url1 = explode("-",substr($url,1));
- foreach($url1 as $val){
- echo $val;
- }
- ?>
- <IfModule mod_rewrite.c>
- RewriteEngine on
- RewriteBase /
- RewriteRule ^search/([^/.]+)/?$ /welworth-search/search.php?q=$1 [NC,L]
- </IfModule>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement