equal
deleted
inserted
replaced
18 // set memory limits |
18 // set memory limits |
19 if ( !defined('WP_MEMORY_LIMIT') ) { |
19 if ( !defined('WP_MEMORY_LIMIT') ) { |
20 if( is_multisite() ) { |
20 if( is_multisite() ) { |
21 define('WP_MEMORY_LIMIT', '64M'); |
21 define('WP_MEMORY_LIMIT', '64M'); |
22 } else { |
22 } else { |
23 define('WP_MEMORY_LIMIT', '32M'); |
23 define('WP_MEMORY_LIMIT', '40M'); |
24 } |
24 } |
25 } |
25 } |
26 |
26 |
27 if ( ! defined( 'WP_MAX_MEMORY_LIMIT' ) ) { |
27 if ( ! defined( 'WP_MAX_MEMORY_LIMIT' ) ) { |
28 define( 'WP_MAX_MEMORY_LIMIT', '256M' ); |
28 define( 'WP_MAX_MEMORY_LIMIT', '256M' ); |
37 */ |
37 */ |
38 if ( ! isset($blog_id) ) |
38 if ( ! isset($blog_id) ) |
39 $blog_id = 1; |
39 $blog_id = 1; |
40 |
40 |
41 // set memory limits. |
41 // set memory limits. |
42 if ( function_exists('memory_get_usage') && ( (int) @ini_get('memory_limit') < abs(intval(WP_MEMORY_LIMIT)) ) ) |
42 if ( function_exists( 'memory_get_usage' ) ) { |
43 @ini_set('memory_limit', WP_MEMORY_LIMIT); |
43 $current_limit = @ini_get( 'memory_limit' ); |
|
44 if ( -1 != $current_limit && ( -1 == WP_MEMORY_LIMIT || ( intval( $current_limit ) < abs( intval( WP_MEMORY_LIMIT ) ) ) ) ) |
|
45 @ini_set( 'memory_limit', WP_MEMORY_LIMIT ); |
|
46 } |
44 |
47 |
45 if ( !defined('WP_CONTENT_DIR') ) |
48 if ( !defined('WP_CONTENT_DIR') ) |
46 define( 'WP_CONTENT_DIR', ABSPATH . 'wp-content' ); // no trailing slash, full paths only - WP_CONTENT_URL is defined further down |
49 define( 'WP_CONTENT_DIR', ABSPATH . 'wp-content' ); // no trailing slash, full paths only - WP_CONTENT_URL is defined further down |
47 |
50 |
48 // Add define('WP_DEBUG', true); to wp-config.php to enable display of notices during development. |
51 // Add define('WP_DEBUG', true); to wp-config.php to enable display of notices during development. |
67 if ( !defined('MEDIA_TRASH') ) |
70 if ( !defined('MEDIA_TRASH') ) |
68 define('MEDIA_TRASH', false); |
71 define('MEDIA_TRASH', false); |
69 |
72 |
70 if ( !defined('SHORTINIT') ) |
73 if ( !defined('SHORTINIT') ) |
71 define('SHORTINIT', false); |
74 define('SHORTINIT', false); |
|
75 |
|
76 // Constants for expressing human-readable intervals |
|
77 // in their respective number of seconds. |
|
78 define( 'MINUTE_IN_SECONDS', 60 ); |
|
79 define( 'HOUR_IN_SECONDS', 60 * MINUTE_IN_SECONDS ); |
|
80 define( 'DAY_IN_SECONDS', 24 * HOUR_IN_SECONDS ); |
|
81 define( 'WEEK_IN_SECONDS', 7 * DAY_IN_SECONDS ); |
|
82 define( 'YEAR_IN_SECONDS', 365 * DAY_IN_SECONDS ); |
72 } |
83 } |
73 |
84 |
74 /** |
85 /** |
75 * Defines plugin directory WordPress constants |
86 * Defines plugin directory WordPress constants |
76 * |
87 * |
291 * Used as the default theme when installing new sites. |
302 * Used as the default theme when installing new sites. |
292 * Will be used as the fallback if the current theme doesn't exist. |
303 * Will be used as the fallback if the current theme doesn't exist. |
293 * @since 3.0.0 |
304 * @since 3.0.0 |
294 */ |
305 */ |
295 if ( !defined('WP_DEFAULT_THEME') ) |
306 if ( !defined('WP_DEFAULT_THEME') ) |
296 define( 'WP_DEFAULT_THEME', 'twentyeleven' ); |
307 define( 'WP_DEFAULT_THEME', 'twentytwelve' ); |
297 |
308 |
298 } |
309 } |