Need some help with a script

Nosence

Senior Member
Joined
Dec 28, 2010
Messages
924
Reaction score
43
Hello,

I am looking to be able to have a searchable function on my site, that allows for search by a zip code and another factor like day of the week.

I dont know really where to begin with this idea, and I really have not been able to find anyone who could help me out.

The site is on wordpress

any help would be greatly appreciated

Thanks
 
Have you looked at using a google search input text box on your site? Or maybe there is a wordpress plugin that will do what you are looking for.
 
I will definitely use google search input text boxon my sites. Lets see what happen.
 
Does your site use php/mysql database?

Have an html form, post the search query, then have something like this on the results page.

$result = mysql_query("SELECT * FROM table WHERE zipcode LIKE '%$zipcode%' AND other='$theother' LIMIT 50")
or die(mysql_error());
while($row = mysql_fetch_array( $result )) {
$thename = $row['name'];
$theid = $row['id'];
echo "$thename - $theid<br>";
}
 
Back
Top