Publishing Failed in WordPress

When you post in WordPress with over 5MB text post, you may receive this error with red color.

Publishing Failed

or you found in your php error log

PHP Fatal error:  Maximum execution time of 60 seconds exceeded in /home/nginx/domains/juzhax.com/public/wp-includes/formatting.php on line 2295

This is because WordPress need more time to execute and process and formatting your post over the maximum execution time.

You may use the way below to solve this.

Edit the file wp-config.php and add in the line


@ini_set('max_execution_time', 1800);

But, use this with caution, because if many of your script in WordPress over this time, this way maybe kill your server.

`require’: cannot load such file — php_serialize (LoadError)

I’m running some of the Ruby script inside Docker and it show me this error.

The solution I use to solve it using the way below.

First, goto the path of your Gemfile

echo “gem ‘php-serialize'” >>Gemfile
bundle install

ERROR: failed to ptrace(PEEKDATA) pid 17402: Input/output error (5)

You may found this error from your php-fpm and the php-fpm crash

[code lang=”shell”]
tail /var/log/php-fpm/error.log
[15-May-2016 12:24:13] ERROR: failed to ptrace(PEEKDATA) pid 17402: Input/output error (5)
[15-May-2016 12:24:13] ERROR: failed to ptrace(PEEKDATA) pid 17777: Input/output error (5)
[15-May-2016 12:24:13] ERROR: failed to ptrace(PEEKDATA) pid 18886: Input/output error (5)
[15-May-2016 12:25:53] ERROR: failed to ptrace(PEEKDATA) pid 17232: Input/output error (5)
[15-May-2016 12:29:13] ERROR: failed to ptrace(PEEKDATA) pid 12091: Input/output error (5)
[15-May-2016 12:29:13] ERROR: failed to ptrace(PEEKDATA) pid 16704: Input/output error (5)
[15-May-2016 12:29:13] ERROR: failed to ptrace(PEEKDATA) pid 17779: Input/output error (5)
[15-May-2016 12:29:13] ERROR: failed to ptrace(PEEKDATA) pid 19015: Input/output error (5)
[15-May-2016 12:30:53] ERROR: failed to ptrace(PEEKDATA) pid 20663: Input/output error (5)
[15-May-2016 12:30:53] ERROR: failed to ptrace(PEEKDATA) pid 21002: Input/output error (5)
[/code]

Solution to stop ERROR: failed to ptrace(PEEKDATA)

You can just comment out the php-fpm config
[code lang=”shell”]
vim /etc/php-fpm.d/www.conf
[/code]

then comment out
[code lang=”shell”]
;slowlog = /var/log/php-fpm/slow.log
;request_slowlog_timeout = 5s
[/code]

ERROR: IITC failed to extract the required parameters from the intel site

I’ve got the error by using IITC for Ingress today

IITC failed to extract the required parameters from the intel site
This can happen after Niantic update the standard intel site. A fix will be needed from the IITC developers.

[code lang=”javascript”]
– var reVersion = new RegExp(‘[a-z]=[a-z].getData\\(\\);[a-z].v="([a-f0-9]{40})";’);
+ var reVersion = new RegExp(‘[a-z].v="([a-f0-9]{40})";’);

– var minified = new RegExp(‘^[a-zA-Z$][a-zA-Z$0-9]$’);
+ var minified = new RegExp(‘^[a-zA-Z$0-9]{1,2}$’);
[/code]

Reference: https://github.com/dwinss/ingress-intel-total-conversion/commit/26c7616d0f8e070451e455e70003c47f1bb279a2

  1. Click the Tampermonkey Button at the Top Right of your Google Browser
  2. Click on Dashboard
  3. Click on IITC: Ingress Intel Map Total Conver….
  4. Jump to the link 12622
  5. Modify like this

[code lang=”javascript”]
window.extractFromStock = function() {
window.niantic_params = {}

// extract the former nemesis.dashboard.config.CURRENT_VERSION from the code
// var reVersion = new RegExp(‘[a-z]=[a-z].getData\\(\\);[a-z].v="([a-f0-9]{40})";’);
var reVersion = new RegExp(‘[a-z].v="([a-f0-9]{40})";’);

// var minified = new RegExp(‘^[a-zA-Z$][a-zA-Z$0-9]$’);
var minified = new RegExp(‘^[a-zA-Z$0-9]{1,2}$’);
[/code]

Then refresh your browser.

invalid object in plist for destination format

Error: invalid object in plist for destination format

When you convert the .plist file to json, you could see this problem


plutil -convert json -e json ./filename.plist
./filename.plist: invalid object in plist for destination format

Solution

Remove the key and date using any editor, then re convert again.

 

<key>some text</key>
<date>2013-06-20T15:31:58Z</date>

 

PHP message: PHP Fatal error: Class ‘WP_List_Table’ not found in

PHP message: PHP Fatal error: Class ‘WP_List_Table’ not found in

You may see this error in WordPress while disabled some plugin, because they plugin is need to use the WP_List_Table class from the WordPress.

Solving the problem

Add this to any of your activated plugin the it will load the class if it is not loaded.


if(!class_exists('WP_List_Table')) :
require_once(ABSPATH . 'wp-admin/includes/class-wp-list-table.php');
endif;