Search found 5 matches
- Mon Nov 05, 2012 1:51 pm
- Forum: PHP - Code
- Topic: MySQL Table Results to Process Another Table Results
- Replies: 1
- Views: 737
MySQL Table Results to Process Another Table Results
Below you will find my code, it's not it all in it's entirety, but shows what's important. I have some custom functions that are being used just to note out. What I have my code doing is searching a MySQL table and displaying all of the results based on the current session user id. Then I loop throu...
- Tue Jul 10, 2012 8:17 pm
- Forum: PHP - Code
- Topic: Zip Code Distance Locator
- Replies: 3
- Views: 1418
Re: Zip Code Distance Locator
Now I have a new task to accomplish. I want to load the results on the page without having to reload the page again using ajax. I'm new to ajax though. Below is what I have, when it submits, the page just reloads without any results. Also, if I put the form's action to search.php, this works, so it'...
- Tue Jul 10, 2012 4:51 pm
- Forum: PHP - Code
- Topic: Zip Code Distance Locator
- Replies: 3
- Views: 1418
Re: Zip Code Distance Locator
Fixed it!
Modified it here.
Modified it here.
Code: Select all
$query = "SELECT name, address, dealerships.city, dealerships.state, locations.zip, phone, lat, lon
FROM dealerships
INNER JOIN locations
ON dealerships.zip = locations.zip" or die(mysql_error());
$result = mysql_query ($query) or die(mysql_error());- Mon Jul 09, 2012 6:10 pm
- Forum: PHP - Code
- Topic: Zip Code Distance Locator
- Replies: 3
- Views: 1418
Re: Zip Code Distance Locator
Here are some captures from phpMyAdmin. There's just a few dummy shops for testing purposes.
http://imgur.com/a/Nz7ii
http://imgur.com/a/Nz7ii
- Mon Jul 09, 2012 5:10 pm
- Forum: PHP - Code
- Topic: Zip Code Distance Locator
- Replies: 3
- Views: 1418
Zip Code Distance Locator
So I've been working on a page to locate shops based on zip code and mile distance. I used this tutorial as a walk-through http://htmlcampus.com/build-a-zip-code-store-locator-application-in-php/ Now I've changed a couple of things like the mySQL table is called locations instead of zip_codes. I've ...