I have installed WordPress 3.8 and now I am trying to install WooCommerce - excelling eCommerce 2.0.20
plugin but every time I am getting this error:
Note: I am trying to install plugin in local machine.
Fatal error: Maximum execution time of 60 seconds exceeded in M:\XAMPP\htdocs\woocommerce\wp-includes\class-http.php on line 1327
I have tried with bellow code:
-
php.ini
(in wp-admin folder)memory_limit = 32M
upload_max_filesize = 100M
upload_max_filesize = 100M
post_max_size = 32M
file_uploads = On -
wp-config.php
set_time_limit(60);
but still I am facing this error. I know this very common issue but I need your help to solve this issue.
I will appreciate If you help me 🙂
Thanks
2 Answers
I had the same problem but it occured while importing the theme-unit-test-data.xml along with its attachments. I am using WP 3.8.1. It’s a WordPress issue so editing the php.ini has no effect. WP uses a hardcoded value (60 secs) for http_request_timeout of WP_Http in class-http.php
.
To solve it, place this code in functions.php
of your currently active theme:
add_filter( 'http_request_timeout', 'mytheme_bump_request_timeout', 100 );
function mytheme_bump_request_timeout(){
return 300; //Change this to your desired timeout value in ms
}