Jump to content

Seperate Directories for Files?


Cloud9247

Recommended Posts

Well,

I have had a membership system set up for about 2 months on my site, [a href=\"http://the-knighthood.net\" target=\"_blank\"]http://the-knighthood.net[/a], and I was wanting to set it up so each user can have their profile viewed at [a href=\"http://the-knighthood.net/~Username~\" target=\"_blank\"]http://the-knighthood.net/~Username~[/a], instead of [a href=\"http://the-knighthood.net/member.php?member=view&profile=4\" target=\"_blank\"]http://the-knighthood.net/member.php?membe...w&profile=4[/a] (too long x_X), but I have no idea how to do this, and I can't seem to get any help off of google, please help!

Thank you,
Cloud9247
Link to comment
https://forums.phpfreaks.com/topic/10133-seperate-directories-for-files/
Share on other sites

okay so i lied a little bit. i kinda sorta know how to do it but not completely.

well i know there is a way to do it by putting some stuff in .htaccess something like

[code]
+FollowSymlinks
RewriteEngine on
RewriteRule ^varname/(.*) http://www.blah.com/profile.php?varname=$1
[/code]

and then when you do like

www.blah.com/CrayonViolent

it takes you to

profile.php?varname=CrayonViolent

and you just get the info via regular means like $_GET or $_REQUEST

i hope that points you in the right direction...

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.