• Resolved daverob

    (@daverob)


    Have read similar postings with similar errors but not found the problem.

    If I go to “Add Gallery/Images”, enter a new gallery title, then drag an image (35k size jpg) it is listed in the filenames area. I click “start upload” and get an immediate error popup:

    “An unexpected error occurred. This is most likely due to a server misconfiguration. Check your PHP error log or ask your hosting provider for assistance.”.

    No directories or files have been created in “galleries” folder.
    If I upload the same image to Media then try “Import from WordPress Media Library” and create a gallery, I get an “Importing Gallery” progress bar that hangs.
    If I enable php logging, I see no errors. File permissions on the wp_content folder are 755.
    I have tried resetting the options under “other options” to no effect.
    After all the above, gallery folder is still empty.
    If I go to “manage Galleries” and use “add new gallery” then I can create a gallery and a corresponding folder appears in the file system of the same name with a thumbs folder in it.
    If I now click on “save changes” I get an error thrown “Class DOMDocument not found”
    If I return to “Add Gallery/images” and attempt again to upload the image I get the same “An unexpected error…..” message but now the image is in the folder, however I can do nothing with it. If I return to “Manage Galleries” and try “Scan folder for new images” I again get the error thrown “Class ‘DOMDocument’ not found”.
    Run out of things to try; any suggestions?

    Wordpress 4.9.5 running Twenty Seventeen theme. OS is Ubuntu 18.04 running under WMware Workstation 12 under Windows 10. PHP version “7.2.3-1ubuntu1”. Apache Apache/2.4.29. All other aspects of WordPress and plugins working correctly. Current active plugins Contact Form 7, Disable Toolbar, The Events Calendar and WP-Members.

Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Cannot add Gallery; “An unexpected error occurred….”’ is closed to new replies.