Hi all, I have been asked to build a website where people purchase a package and create their own profile for their hobbies. Most will have their own domain so how would I go about linking the profile up to the domain? Ideally everything should be automated and the end user will have no technical understanding.
Take their name lets say “Bob O’Marley” and turn it into a url friendly “slug” bobomarley.
Make sure that is unique, or add something to it that makes it unique. bobomarley2
(search just this forum for the term slug or slugify to find examples and discussion on this)
Then…
read up on Apache’s mod_rewrite and make it so that all requests for www.example.com/users/jonny actually go to :
Then index.php queries your database and presents jonnys’ details, but the users address bar will still show your lovely unique url.
(you can search several SP forums for more info on mod_rewrite, including this one)
Good to hear from you. Your answer is close to what I was asking, but I didn’t explain clearly enough. People can have their own profile domain such as www.example.com/users/jonny OR they can point their own domain such as www.jonny.com. Not sure how this could be handled??
Hi Cups, so when a user points their domain to my server, how do I then make sure that their domain goes to their profile page? This is what I seem to be stuck on…?