What code do I need to use to display the WordPress memory limit and WordPress maximum memory limit.
In PHP for example, I can just get the memory limit by using:
echo $memory_limit = ini_get('memory_limit');
What would be a similar equivalent in WordPress?
What code do I need to use to display the WordPress memory limit and WordPress maximum memory limit.
In PHP for example, I can just get the memory limit by using:
echo $memory_limit = ini_get('memory_limit');
What would be a similar equivalent in WordPress?
Share Improve this question edited Sep 30, 2019 at 13:37 butlerblog 5,1213 gold badges28 silver badges44 bronze badges asked Sep 30, 2019 at 11:43 chinazaikechinazaike 1072 bronze badges 4 |1 Answer
Reset to default 1Resolved via this functions as suggested by Rup
wp_is_ini_value_changeable( 'memory_limit' )
source link
发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745118530a4612276.html
wp_raise_memory_limit
. Is that what you meant? Are your applications using this as a matter of course? They probably shouldn't be. At first glance that's just the WP_MAX_MEMORY_LIMIT constant, ifwp_is_ini_value_changeable( 'memory_limit' )
is true. – Rup Commented Sep 30, 2019 at 12:07