r00tk1LL Posted March 3, 2009 Share Posted March 3, 2009 What I am basically trying to do is create a rule that when some one browses to www.mysite.com/username it redirects the user to a dynamically generated profile page (I.E. profile.php using the username as a variable) and if they go to www.mysite.com it takes you to the home page... Is this the right approach to take, if so how would I go about it? If not what would be the right approach to give users their own profile urls?? Thanks Quote Link to comment https://forums.phpfreaks.com/topic/147766-how-to-create-user-profile-urls/ Share on other sites More sharing options...
rhodesa Posted March 3, 2009 Share Posted March 3, 2009 you can do that, but it restricts what your folder and page names can be. i would do the profile pages like: www.mysite.com/user/username then you can do an apache mod_rewrite in an .htaccess file to map those to: www.mysite.com/user.php?user=username Quote Link to comment https://forums.phpfreaks.com/topic/147766-how-to-create-user-profile-urls/#findComment-775684 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.