Insert Into Post Error
-
Hi I just had a call from a customer that can no longer insert attachments into the page using default page editor, since updating to WordPress 3.6.1 she had no issues previously to this.
She clicks “Add Media” and then successfully uploads her content (in this case a pdf, but attempted with images jpeg/png also) but when she hits insert into post nothing happens.
I looked into the problem myself and find when using “insert into post” wordpress makes an ajax call to “/wp-admin/admin-ajax.php” which returns the message “Security check failed” looking into the ajax call I’ve found that it successfully calls the function “wp_ajax_send_attachment_to_editor” (line 1974 of /wp-admin/includes/ajax-actions.php) and this is where I am not sure what is failing the only security call I can see is “if ( current_user_can( ‘edit_post'” (line 1987) and the current user has the correct permissions and is able to edit the post, it only fails when trying to add media to the page, she can add text save and publish.
If anybody can spread some light onto why this might be happening I would be very grateful.
The topic ‘Insert Into Post Error’ is closed to new replies.