Tell me more ×
Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.

My website users have a profiles. I want other users to access their profiles by specific url like:

www.mysite.com/username

Users can also access a specific parts in the user profile like that

www.mysite.com/username/albums/album1

How can i do this?

share|improve this question
Normally these kinds of questions are migrated to Stack Overflow. But due to its low quality nature they will close it as soon as they receive it so I am just going to close it here. – John Conde Nov 3 '12 at 17:34

closed as off topic by John Conde Nov 3 '12 at 17:33

Questions on Webmasters Stack Exchange are expected to relate to webmastering within the scope defined in the FAQ. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about closed questions here.

1 Answer

In the code of "www.mysite.com/username" put this javascript code:

<script type="text/javascript">
    window.location("www.mysite.com/username/albums/album1");
</script>

Other ways of redirecting can be found at:

share|improve this answer
username and albums is daynamic, i think it maybe done by .htaccess. Are you have any idea ? – Mohamed Nagy Nov 3 '12 at 7:41
you can have a php code for that (if your site is written in php)! – Pranit Bauva Nov 3 '12 at 16:22

Not the answer you're looking for? Browse other questions tagged or ask your own question.