3 * Configuration for "min", the default application built with the Minify
11 * Allow use of the Minify URI Builder app. Only set this to true while you need it.
13 $min_enableBuilder = false;
16 * If non-empty, the Builder will be protected with HTTP Digest auth.
17 * The username is "admin".
19 $min_builderPassword = 'admin';
23 * Set to true to log messages to FirePHP (Firefox Firebug addon).
24 * Set to false for no error logging (Minify may be slightly faster).
25 * @link http://www.firephp.org/
27 * If you want to use a custom error logger, set this to your logger
28 * instance. Your object should have a method log(string $message).
30 $min_errorLogger = false;
34 * To allow debug mode output, you must set this option to true.
36 * Once true, you can send the cookie minDebug to request debug mode output. The
37 * cookie value should match the URIs you'd like to debug. E.g. to debug
38 * /min/f=file1.js send the cookie minDebug=file1.js
39 * You can manually enable debugging by appending "&debug" to a URI.
40 * E.g. /min/?f=script1.js,script2.js&debug
42 * In 'debug' mode, Minify combines files with no minification and adds comments
43 * to indicate line #s of the original files.
45 $min_allowDebugFlag = false;
49 * For best performance, specify your temp directory here. Otherwise Minify
50 * will have to load extra code to guess. Some examples below:
52 //$min_cachePath = 'c:\\WINDOWS\\Temp';
53 //$min_cachePath = '/tmp';
54 //$min_cachePath = preg_replace('/^\\d+;/', '', session_save_path());
56 * To use APC/Memcache/ZendPlatform for cache storage, require the class and
57 * set $min_cachePath to an instance. Example below:
59 require dirname(__FILE__) . '/lib/Minify/Cache/File.php';
60 $min_cachePath = new Minify_Cache_File(dirname(__FILE__) . '/../cache');
64 * Leave an empty string to use PHP's $_SERVER['DOCUMENT_ROOT'].
66 * On some servers, this value may be misconfigured or missing. If so, set this
67 * to your full document root path with no trailing slash.
68 * E.g. '/home/accountname/public_html' or 'c:\\xampp\\htdocs'
70 * If /min/ is directly inside your document root, just uncomment the
71 * second line. The third line might work on some Apache servers.
73 $min_documentRoot = '';
74 //$min_documentRoot = substr(__FILE__, 0, -15);
75 //$min_documentRoot = $_SERVER['SUBDOMAIN_DOCUMENT_ROOT'];
79 * Cache file locking. Set to false if filesystem is NFS. On at least one
80 * NFS system flock-ing attempts stalled PHP for 30 seconds!
82 $min_cacheFileLocking = true;
86 * Combining multiple CSS files can place @import declarations after rules, which
87 * is invalid. Minify will attempt to detect when this happens and place a
88 * warning comment at the top of the CSS output. To resolve this you can either
89 * move the @imports within your CSS files, or enable this option, which will
90 * move all @imports to the top of the output. Note that moving @imports could
91 * affect CSS values (which is why this option is disabled by default).
93 $min_serveOptions['bubbleCssImports'] = false;
97 * Cache-Control: max-age value sent to browser (in seconds). After this period,
98 * the browser will send another conditional GET. Use a longer period for lower
99 * traffic but you may want to shorten this before making changes if it's crucial
100 * those changes are seen immediately.
102 * Note: Despite this setting, if you include a number at the end of the
103 * querystring, maxAge will be set to one year. E.g. /min/f=hello.css&123456
105 $min_serveOptions['maxAge'] = 1800;
109 * To use Google's Closure Compiler API to minify Javascript (falling back to JSMin
110 * on failure), uncomment the following line:
112 //$min_serveOptions['minifiers']['application/x-javascript'] = array('Minify_JS_ClosureCompiler', 'minify');
116 * If you'd like to restrict the "f" option to files within/below
117 * particular directories below DOCUMENT_ROOT, set this here.
118 * You will still need to include the directory in the
119 * f or b GET parameters.
121 * // = shortcut for DOCUMENT_ROOT
123 //$min_serveOptions['minApp']['allowDirs'] = array('//js', '//css');
126 * Set to true to disable the "f" GET parameter for specifying files.
127 * Only the "g" parameter will be considered.
129 $min_serveOptions['minApp']['groupsOnly'] = false;
133 * By default, Minify will not minify files with names containing .min or -min
134 * before the extension. E.g. myFile.min.js will not be processed by JSMin
136 * To minify all files, set this option to null. You could also specify your
137 * own pattern that is matched against the filename.
139 //$min_serveOptions['minApp']['noMinPattern'] = '@[-\\.]min\\.(?:js|css)$@i';
143 * If you minify CSS files stored in symlink-ed directories, the URI rewriting
144 * algorithm can fail. To prevent this, provide an array of link paths to
145 * target paths, where the link paths are within the document root.
147 * Because paths need to be normalized for this to work, use "//" to substitute
148 * the doc root in the link paths (the array keys). E.g.:
150 * array('//symlink' => '/real/target/path') // unix
151 * array('//static' => 'D:\\staticStorage') // Windows
154 $min_symlinks = array();
158 * If you upload files from Windows to a non-Windows server, Windows may report
159 * incorrect mtimes for the files. This may cause Minify to keep serving stale
160 * cache files when source file changes are made too frequently (e.g. more than
163 * Immediately after modifying and uploading a file, use the touch command to
164 * update the mtime on the server. If the mtime jumps ahead by a number of hours,
165 * set this variable to that number. If the mtime moves back, this should not be
168 * In the Windows SFTP client WinSCP, there's an option that may fix this
169 * issue without changing the variable below. Under login > environment,
170 * select the option "Adjust remote timestamp with DST".
171 * @link http://winscp.net/eng/docs/ui_login_environment#daylight_saving_time
173 $min_uploaderHoursBehind = 0;
177 * Path to Minify's lib folder. If you happen to move it, change
180 $min_libPath = dirname(__FILE__) . '/lib';
183 // try to disable output_compression (may not have an effect)
184 ini_set('zlib.output_compression', '0');