How do I use htaccess to make a short URL to a MediaWiki page?
How do I use htaccess to make a short URL to a MediaWiki page? -
Solution :
Additionally, if you would like to do some further testing, give the htaccess tester tool a try. It allows you to specify a certain URL as well as the rules you would like to include and then shows which rules were tested, which ones met the criteria, and which ones were executed.
.htaccess files are extremely useful in many cases for users who either do not have root permissions or for users who simply aren't comfortable in making changes in their web server's configuration file. Trying to debug .htaccess not working isn't always the easiest thing to do, however, hopefully by checking the discuss below mentioned about htaccess, url, apache, url-rewriting, .htaccess common problems as well as the troubleshooting tips, you'll have a better grasp on what you may have to modify to get your .htaccess file running smoothly.Problem :I'd like to rewrite /liam to /index.php/Liam_Edwards-Playne. I've currently written this below in the appropriate .htaccess file but it is still returning a 404:
RewriteEngine On
RewriteRule ^/liam$ %DOCUMENT_ROOT/index.php/Liam_Edwards-Playne [NC,L]
You shouldn't need the DOCUMENT_ROOT variable. Simply doing:
RewriteRule ^liam$ /index.php/Liam_Edwards-Playne [NC,L]
is sufficient for mod_rewrite
Comments
Post a Comment