Jump to content

aarondm

New Members
  • Posts

    2
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

aarondm's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Hi, having problem removing the query string so that it doesnt show up in our new rewritten url...the [QSD] query string discad doesnr remove the query string and causes and internal error:- code is: RewriteEngine on RewriteCond %{QUERY_STRING} ^name=Tamarind%20Cove%20Hotel&island=barbados&resort_id=48$ [NC] RewriteRule ^luxury-hotel-resort/index.php$ /luxury-hotel-resort/Tamarind-Cove-Hotel--barbados-resort---48 [R=301,L,NC,QSD] RewriteRule ^luxury-hotel-resort/(.*)--(.*)-resort---(.*)$ /luxury-hotel-resort/index.php?name=$1&island=$2&resort_id=$3&redirect=0 [L] old page is : http://www.prestige-caribbean.com/luxury-hotel-resort/index.php?name=Tamarind Cove Hotel&island=barbados&resort_id=48 new page after rewrite and redirect to is:- http://www.prestige-caribbean.com/luxury-hotel-resort/Tamarind-Cove-Hotel-barbados-resort_id=48 any suggestions very much appreciated for this and how I can use one rewrite to change all URLS in the /luxury-hotel-resort/ section as they folow the same url structure, rather adding each one separately as I add new pages thanks
  2. Hi, having problems getting checkboxes to display all reuslts when a user selects more than one check box say in the category section and one in the location section - see page http://www.partyco.co.uk/event-and-party-venues/ - submit to see reults page: I managed to get it to display reults if the user only seletc either a right or left column option OR one of each - BUT not when thet select multiple categories and one location - and ideas how to do this ? putting it into an array perhaps - but how - new to some of this.... here is the code for the reults page: <?php $location = $_POST[location]; $category = $_POST[category]; ?> <?php $Link = mysql_connect("xxxxxxxxx", "xxxxxxxxx", "xxxxxxxx") or die(mysql_error()); mysql_select_db("xxxxxxxx") or die(mysql_error()); // selects db listings when location not given if (empty($location)) { $query = "SELECT * FROM venues WHERE category = '$category' order by title"; $result = mysql_query($query) or die(mysql_error()); // selects db listings when category not given } elseif(empty($category)) { $query = "SELECT * FROM venues WHERE location = '$location' order by title"; $result = mysql_query($query) or die(mysql_error()); // selects db listings when both given }else { $query = "SELECT * FROM venues WHERE category = '$category' and location = '$location' order by title"; $result = mysql_query($query) or die(mysql_error()); } while($row = mysql_fetch_array($result)){ echo "<div class=\"resultsShort\" style=\"margin-bottom:10px;\">"; echo "<h2 id=\"resultsHeading\">"; echo $row['title']; echo "</h2>"; echo "<p class\"resultspara\">". nl2br($row['description']). "</p>"; echo "<h4 style=\"margin:5px 0 0 0; padding:0;\">Contact details</h4>"; echo "<p class\"resultspara\">". nl2br($row['contact']). "</p>"; echo "<div style=\"float:left; width:124px; height:40px; margin:10px 15px 0 0;\">"; echo "<a href=\"/party-supplier-resources/email-supplier.php?title=". $row['title']. "&email=" . $row['email']. "&location=" . $row['location']. "&category=" . $row['category']. "\" title=\"contact this venue here\">"; echo "<img src=\"/images/email-supplier.jpg\" width=\"124\" align=\"right\" height=\"35\" alt=\"contact this supplier button\" border=\"0\" /></a>"; echo "</div>"; echo "</div>"; } ?> <?php include("../include/shareLinks.php"); ?> <div id="popupContact"> <a id="popupContactClose" title="close this window">close x</a> <h1>Supplier Directory Enquiry Form</h1> <?php include("../include/enquiryform.php"); ?> </div> <div id="backgroundPopup"></div> <?php mysql_close ($Link); ?> Any help appreciated! Aaron MOD EDIT: . . . BBCode tags added.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.