keenk Posted July 13, 2006 Share Posted July 13, 2006 this is a slightly more general question but as i am programming it in php, it is related.i am wondering what is the best way to create clean user-specific urls for each user registered on a website. i explain. take del.icio.us for example. a user's main url is 'http://del.icio.us/username' and match with its rss feed 'http://del.icio.us/rss/username'. i am wondering if when the user registers, different folders are created (/username, and /rss/username) with files in them. how does it work? Quote Link to comment https://forums.phpfreaks.com/topic/14522-user-directories-management/ Share on other sites More sharing options...
micah1701 Posted July 13, 2006 Share Posted July 13, 2006 I'm not sure exactily how that site does it, but its probably not individual directories.check out this article at sitepointhttp://www.sitepoint.com/article/search-engine-friendly-urls Quote Link to comment https://forums.phpfreaks.com/topic/14522-user-directories-management/#findComment-57509 Share on other sites More sharing options...
Kurt Posted July 13, 2006 Share Posted July 13, 2006 They probably use .htaccess to do this. Quote Link to comment https://forums.phpfreaks.com/topic/14522-user-directories-management/#findComment-57510 Share on other sites More sharing options...
keenk Posted July 13, 2006 Author Share Posted July 13, 2006 thanks that's exactly what i needed.if del.icio.us use .htaccess by redirecting error pages, they must have one hell of an error log. Quote Link to comment https://forums.phpfreaks.com/topic/14522-user-directories-management/#findComment-57523 Share on other sites More sharing options...
ShogunWarrior Posted July 13, 2006 Share Posted July 13, 2006 Nope, they probably use [url=http://httpd.apache.org/docs/2.0/mod/mod_rewrite.html]mod_rewrite[/url], an addon for Apache which allows for rewriting of URLs to the backend.Note that when you rewrite a URL e.g: [b]/user3/[/b] to backend [b]?user.php?id=3[/b] that the browser will look for images etc. in www.site.com/user3/ so you have to hardcode your resources. It's handy to know before you start. Quote Link to comment https://forums.phpfreaks.com/topic/14522-user-directories-management/#findComment-57530 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.