Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- RewriteEngine On
- RewriteMap lc int:tolower
- RewriteCond %{REQUEST_URI} [A-Z]
- RewriteRule (.*) ${lc:$1} [R=301,L]
- /home/public_html/.htaccess: RewriteMap not allowed here
- [Mon Jul 18 10:33:06 2011] [alert] [client *.*.*.*] /home/public_html/.htaccess: RewriteMap not allowed here
- $url = $_SERVER['REQUEST_URI'];
- $pattern = '/([A-Z]+)/';
- if(preg_match($pattern, $url)) {
- $new_url = strtolower($url);
- Header( 'HTTP/1.1 301 Moved Permanently' );
- Header( 'Location: ' . $new_url );
- exit;
- }
- // your code here
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement