I have been learning PHP for about a month now, and I am working on a large project that requires a lot of it. My project involves the Google Maps API and I have a database that populates my map with information collected from a form.
As you can see a link is created in the marker using the state, city and name.Code:var html = '<b>' + name + '</b> <br/>' + address + '<br />' + '<a href=\"/locations/' + state + '/' + city + '/' + name + '\">View Profile</a>';
Now that I have determined a URL path, I need to actually create it. I need a way to go through the database and create a file and file path for each one, this will be a "Profile" page for each location.
I know how to use fopen to create a file, I just dont know how to use a variable
$namefor the file and I cant find a guide that explains how to determine the file path, which in my case would be
location/$state/$city/and then the actual file.
Any help would be greatly appreciated, it somewhat hard to explain the ultimate goal I envision so if you need more details I will certainly give them.
If you know of any guides anywhere that relate to this in some way that would work perfectly.