Commit:    1b57979f5a66b45d0a7ec1b837c40bae2eab23e9
Author:    Peter Cowburn <[email protected]>         Thu, 3 Oct 2013 
14:31:22 +0100
Parents:   703a5cbfba0f924c56ff85095f260368435909a0
Branches:  master

Link:       
http://git.php.net/?p=web/people.git;a=commitdiff;h=1b57979f5a66b45d0a7ec1b837c40bae2eab23e9

Log:
better rewrite for username short url

TODO: fix HTML so short urls can have a trailing slash

Changed paths:
  M  .htaccess


Diff:
diff --git a/.htaccess b/.htaccess
index 939e99b..9fb12df 100644
--- a/.htaccess
+++ b/.htaccess
@@ -2,4 +2,4 @@ RewriteEngine On
 
 RewriteCond %{REQUEST_FILENAME} !-f
 RewriteCond %{REQUEST_FILENAME} !-d
-RewriteRule ^(.*)$ http://%{HTTP_HOST}/user.php?username=$1 [L,QSA,R=302]
\ No newline at end of file
+RewriteRule ^([^/]+)/?$ /user.php?username=$1 [L,QSA]


--
PHP Webmaster List Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to