soltek Posted December 27, 2010 Share Posted December 27, 2010 Today I noticed something quite strange on youtube. This: http://www.youtube.com/user/mcgloomy Not the profile by itself, but the way the username can be added there to take us to the profile. I mean, USER must be a folder, but I really doubt MCGLOOMY is another folder, even if it looks like it is. I've read about using htaccess to hide the file name of a folder, but... How does this youtube thingy happens? Link to comment https://forums.phpfreaks.com/topic/222746-urlorguserusername-wtf/ Share on other sites More sharing options...
KevinM1 Posted December 27, 2010 Share Posted December 27, 2010 Neither user nor the username need to be a folder. Most likely, YouTube is written using the MVC (Model View Controller) pattern. 'user' is the name of a controller, and 'username' is the argument passed into it's default action. Link to comment https://forums.phpfreaks.com/topic/222746-urlorguserusername-wtf/#findComment-1151838 Share on other sites More sharing options...
Zurev Posted December 27, 2010 Share Posted December 27, 2010 The joys of mod rewrite. http://httpd.apache.org/docs/1.3/mod/mod_rewrite.html Link to comment https://forums.phpfreaks.com/topic/222746-urlorguserusername-wtf/#findComment-1151843 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.