When adding an entry in Server Configuration -> Website Redirects, type "Directory on this system", and "Include sub-paths in redirect" set to yes, Virtualmin correctly creates an "AliasMatch" directive.
To make proper use of that, I have to include the matched part of the URL expression in the directory path, in form of the text "$1". The help text für "Include sub-paths" correctly states so:
However, if Yes is chosen you can use the special code $1 in the destination URL. This will be replaced by the sub-path or filename that comes after the source URL path.
However, when I try to do that, I get:
Failed to save redirect : Missing or non-absolute destination directory
While this message is technically correct, since there is no (exemplary) path /home/domainname/public_html/joomla/$1
on my system, the message is still rather unfortunate in this situation. :-)
Comments
Submitted by JamieCameron on Tue, 02/01/2011 - 13:23 Comment #1
Thanks for pointing this out - the bug is that Virtualmin checks that the destination directory exists, even though the $1 gets substituted for something else, which makes the check invalid.
I will fix this in the 3.84 release. The work-around till then is to create the directory that ends with $1 , which will never be used but will satisfy the check.
Submitted by Locutus on Wed, 02/02/2011 - 14:33 Comment #2
Roger, and you're welcome!