title: Custom URL for each user in PHP
body: <p>Is it possible to have a website where each user gets their own URL like:
  www.thewebsite.com/myusername</p>
  
  <p>I want each user site to be the same, the only reason the name matters is if a person visiting the site signs up, they get their own custom url, but the person they signed up under is kept track of as their "Parent".</p>
  
  <p>So if I go to www.thewebsite.com/phil and sign up as David, then my site becomes www.thewebsite.com/david but Phil is kept track of in my user record. (i.e. is there a way for me to know which url they visited the site under)</p>
  
  <p>So, really that's 2 questions:</p>
  
  <p>1) How do I make custom urls per user
  2) How do I know which url a new user visited from</p>
  
  <p>I'm pretty brand new to PHP so keep that in mind.</p>