WordPress.org

Support

Support » Themes and Templates » Media Uploader broken in debug mode

Media Uploader broken in debug mode

  • Tim Smith

    @creativeinfusion

    Using Toolbox theme with WP_DEBUG set to true causes the new media library to not display anything either for the whole library or the uploaded to this post.

    When trying to upload images, after upload completes and the image is attached to the post, the new media library shows an error message. The images was uploaded and attached as the main media->library shows them.

    Using the old media uploader, gallery tab shows the following:
    PHP Notice: Trying to get property of non-object in …/wp-content/themes/toolbox/functions.php on line 298
    PHP Notice: Trying to get property of non-object in …/wp-content/themes/toolbox/functions.php on line 300

    The enhanced_image_navigation function uses the global post which isn’t set in this use case. Changing the function to use the post id passed by the attachment_link filter fixes the issue.

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Media Uploader broken in debug mode’ is closed to new replies.