Apply patch from Bug 17056 - list items in Special:NewPages should
[lhc/web/wiklou.git] / thumb.config.sample
1 <?php
2 /**
3 * @cond file_level_code
4 * This is not a valid entry point, perform no further processing unless THUMB_HANDLER is defined
5 */
6 if ( !defined( 'THUMB_HANDLER' ) ) {
7 echo "This file is part of MediaWiki and is not a valid entry point\n";
8 die( 1 );
9 }
10
11 /**
12 * Sample configuration file for thumb-handler.php.
13 * In order to use thumb-handler.php:
14 * 1) Copy this file to thumb.config.php and modify the settings.
15 * 2) The webserver must be setup to have thumb-handler.php as a 404 handler.
16 * This can be done in apache by editing .htaccess in the /thumb directory by adding:
17 * <IfModule rewrite_module>
18 * RewriteEngine on
19 * RewriteCond %{REQUEST_FILENAME} !-f
20 * RewriteCond %{REQUEST_FILENAME} !-d
21 * RewriteRule ^([^/]+/)?[0-9a-f]/[0-9a-f][0-9a-f]/[^/]+/[^/]+$ /path/to/thumb_handler.php [L]
22 * </IfModule>
23 */
24
25 $thgThumbUrlMatch = array(
26 # URL name of the server (e.g. "upload.wikipedia.org").
27 'server' => 'http://localhost',
28 # URL fragment to the thumb/ directory
29 'dirFragment' => 'MW_trunk/images/thumb',
30 # URL regex fragment correspond to the directory hashing of thumbnails.
31 # This must correspond to $wgLocalFileRepo['hashLevels'].
32 'hashFragment' => '[0-9a-f]/[0-9a-f][0-9a-f]/' // 2-level directory hashing
33 );
34
35 $thgThumbCurlConfig = array(
36 # Optionally cURL to thumb.php instead of using it directly
37 'enabled' => false,
38 # The URL to thumb.php, accessible from the web server.
39 'url' => 'http://localhost/MW_trunk/thumb.php',
40 # Optional proxy server to use to access thumb.php
41 'proxy' => null,
42 # Timeout to use for cURL request to thumb.php.
43 # Leave it long enough to generate a ulimit timeout in ordinary
44 # cases, but short enough to avoid a local PHP timeout.
45 'timeout' => 53
46 );
47
48 # Custom functions for overriding aspects of thumb handling
49 $thgThumbCallbacks = array();