Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8924873
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T07:32:15+00:00 2026-06-15T07:32:15+00:00

I am working on a social networking site. Something that I would like to

  • 0

I am working on a social networking site. Something that I would like to do is have the user’s username come after my websites name… like example.com/myusername. I know I could do something using $_GET variables where it would look like example.com/?u=myusername, but we think that having just the username after after the domain would look cleaner and be easier for users to navigate.

Thanks in advance,

JS

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T07:32:17+00:00Added an answer on June 15, 2026 at 7:32 am

    You can setup a rewrite rule to direct all non-existent requests to your index.php (or really whatever script you want to use). Then just inspect the $_SERVER['REQUEST_URI'] and pull out the username.

    Here’s a basic set of rewrite rules (for apache):

    RewriteEngine On
    RewriteCond %{REQUEST_FILENAME} -s [OR]
    RewriteCond %{REQUEST_FILENAME} -l [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^.*$ - [NC,L]
    RewriteRule ^.*$ index.php [NC,L]
    

    And in your case:

    $requestParts = explode('/', $_SERVER['REQUEST_URI'];
    $username = $requestParts[0];
    

    That would allow you to also use: example.com/username/posts/newest, and pull out the various ‘parts’.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am working on social networking site where user can post photo and text
I'm working on a website that will use features of social networking (like facebook
I am working on a social networking site and it has a wall like
I am working on social networking site. now our team decide to store user
I am working on a social networking site with a family tree that is
I am currently working on a social networking website, and I would like the
I am developing a social networking site. It has functionality like user registration, people
About to start working on a social networking site, but I'd like to incorporate
I'm writing a social networking app that has contacts sync functionality. I have working
I'm working on a social networking system that will have comments coming from several

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.