On 11/19/06, Benjamin Yang bingyang@mindspring.com wrote:
Very happy that Brion's suggestion worked for you. I am looking for a solution to solve the same problem. I would appreciate it greatly if you can share the solution in a step-by-step fashion -- like what
Assume that my MediaWiki is installed in "/path/to".
First, in LocalSettings.php, I changed $wgUploadPath:
$wgUploadPath = "/path/to/img_auth.php";
Second, in my /path/to/images directory, I created an .htaccess containing one line:
Deny from All
Third, in my httpd.conf file I created two alias statements and restarted Apache:
Alias /w/images/ /path/to/img_auth.php Alias /w/images /path/to/img_auth.php
Dan
Dan Davis wrote:
Third, in my httpd.conf file I created two alias statements and restarted Apache:
Alias /w/images/ /path/to/img_auth.php Alias /w/images /path/to/img_auth.php
By the way: I believe that with this Alias set up, you could set $wgUploadPath to a more attractive "/w/images" to get cleaner-looking URLs.
-- brion vibber (brion @ pobox.com)
mediawiki-l@lists.wikimedia.org