Jump to content

[SOLVED] Unique urls to pages that may change


SirChick

Recommended Posts

I need help here, i duno what kinda thing im looking for to do this but ill give an example,

 

Say in my database i have "places"

Now what i wanted to do is load up these places like:

 

South

North

West

 

etc

But as these are loaded they need to be urls to that particular place, but i don't know how this would be done because the places may change like West may not be there any more and it could change to East.. so i cant hard code the url as west cos then if u wanted to go east it would still be taking you west =/

 

I been trying to do it for businesses so like it lists all businesses and itll take you the business you clicked on ... how would the page know the url name of that business :S?

Link to comment
Share on other sites

ok let me just explain slightly different ... an example:

 

say you have list of users...

 

user 1

user 2

user 3

 

now what i want is when the user clicks on one of them 3 it'll take them to that peron's profile.

 

Now obviously each user can't have their .php script so it would be ludicrous to do localhost/user1.php or localhost/user2.php and so on and so on..

 

yet some how when the user selects on of them itll take them to their profile.. (obviously by sending some kinda value) but how does it send the value and what value would it send :S

Link to comment
Share on other sites

Echo'<a href="business.php?biz=<?={$GetCommercialResult['BusinessID']};?>"><?={$GetCommercialResult['BusinessName']}?></a>';

That is what i put but it is not working,

 

i get this as an error:

 

Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in C:\xampp\htdocs\londoncommercial.php on line 12

 

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.