• Resolved djmacbest

    (@djmacbest)


    This webpage is for a seniors’ golf group and I want to spare them the hassle of having to learn the new editor, so I want to keep with the Classic Editor.

    However: The “Add Media” button does not work. When I click it, nothing happens. The Media library overview appears empty as well, but the website users have uploaded lots of pictures through the editor for use in posts already over the years.

    Troubleshooting so far, after googling a bit and reading in this forum a bit:
    – tried current Chrome and Firefox
    – disabled all Plugins
    – switched to Twenty Nineteen theme
    – tried adding the following line to wp-config:
    define('CONCATENATE_SCRIPTS', false );

    None of these measures had any visible effect on the problem.

    Error message in Chrome console as follows when clicking on “Add Media”:

    Uncaught TypeError: Cannot read property 'states' of undefined
        at n._createStates (media-views.min.js?ver=5.0.3:1)
        at n.initialize (media-views.min.js?ver=5.0.3:1)
        at n.initialize (media-views.min.js?ver=5.0.3:1)
        at n.initialize (media-views.min.js?ver=5.0.3:1)
        at n.initialize (media-views.min.js?ver=5.0.3:1)
        at n.e.View (backbone.min.js?ver=1.2.3:1)
        at n.constructor (wp-backbone.min.js?ver=5.0.3:1)
        at n.constructor (media-views.min.js?ver=5.0.3:1)
        at n [as constructor] (backbone.min.js?ver=1.2.3:1)
        at n [as constructor] (backbone.min.js?ver=1.2.3:1)

    Error message in Chrome console as follows when viewing Media Library:

    Uncaught TypeError: Cannot read property 'uploader' of undefined
        at n.initialize (media-grid.min.js?ver=5.0.3:1)
        at n.e.View (backbone.min.js?ver=1.2.3:1)
        at n.constructor (wp-backbone.min.js?ver=5.0.3:1)
        at n.constructor (media-views.min.js?ver=5.0.3:1)
        at n [as constructor] (backbone.min.js?ver=1.2.3:1)
        at n [as constructor] (backbone.min.js?ver=1.2.3:1)
        at new n (backbone.min.js?ver=1.2.3:1)
        at Object.wp.media (media-models.min.js?ver=5.0.3:1)
        at HTMLDocument.<anonymous> (media.min.js?ver=5.0.3:1)
        at i (jquery.js?ver=1.12.4:2)

    Appreciate any help and suggestions! Thank you in advance!

Viewing 4 replies - 1 through 4 (of 4 total)
  • I tried it on 5.0.3 with two different versions of the Classic Editor plugin, and it works fine. The error you are getting indicates that some of the javascript is not loaded. Did your site update correctly or was there an error? You could try the Reinstall button to see if that helps.

    Thread Starter djmacbest

    (@djmacbest)

    I tried it on two separate computers before and after updating to 5.0.3. Another wp blog I’m hosting works fine (also on both computers).

    Initially, yes, there were some problems during the update process (some write restrictions in server configuration, but I fixed those and reapplied the update with no problems), but I didn’t look into it since it didn’t work before the update (at 4.9.something) either. I’ll try reinstalling, maybe that does something.

    Thank you!

    Moderator Samuel Wood (Otto)

    (@otto42)

    WordPress.org Admin

    Does it work if you open the site and login in an “Incognito Mode” tab?

    Thread Starter djmacbest

    (@djmacbest)

    I finally solved the issue, after trying on a third computer.

    On both other computers I apparently tried to use the button before updating wordpress, so some bad javascript has remained in the browser cache. I didn’t think of clearing it because it happened on two separate computers, but clearing the cache solved the problem.

    Thank you all for your help!

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Classic Editor: “Add Media” button doesn’t work’ is closed to new replies.