Import error with indexed custom status
-
Hello,
I have a really strange bug ??
There are custom post types and custom post status in my blog. In my functions.php I’m using the following filters for indexing custom post status:
function relevanssi_add_status($status_array) { $status_array[] = "prepublish"; $status_array[] = "archive"; return $status_array; } add_filter('relevanssi_valid_status', 'relevanssi_add_status'); add_filter('relevanssi_valid_admin_status', 'relevanssi_add_status'); function relevanssi_allow_custom_status($post_ok, $post_id) { $status = relevanssi_get_post_status($post_id); if($status == 'prepublish' || $status == 'archive') { $post_ok = true; } return $post_ok; } add_filter('relevanssi_post_ok', 'relevanssi_allow_custom_status', 11, 2);
Yesterday, I’ve updated the PHP version from 5.4 to 7.1.7. Now, when I import big data ( > 2.000 posts, post type “product”, post status “archive”), I get server error 500. First, I thought it must be something in php.ini file; I tried to increase some values for
memory_limit
,max_execution_time
,post_max_size
andupload_max_filesize
but nothing changed.
I also tried different themes and deactivating plugins – same behaviour.
For importing, I use WP Re-Importer plugin. I also tried to import with WP Importer and WP All Import – same behaviour.When I deactivate Relevanssi the import is working. When Relevanssi is activated and I outcomment the status who is used in the import file
$status_array[] = "archive";
the import is working fine too (or when I switch back to PHP 5.4). Otherwise the import is failing with the server error 500.I’m running out of ideas – do you have any idea?
Best regards
saNNNy
- The topic ‘Import error with indexed custom status’ is closed to new replies.