Skip to content

Images do not upload or disappear

Get uploads working and keep uploaded files on the site. Images reach the page through the builder's own upload, or through the Media Library when the site uses it. Most failures are media settings, file permissions, or an upload that never reached the server.

The media browser is missing or opens empty

  1. Go to DXPR Studio > DXPR Builder > General Settings (/admin/dxpr_studio/dxpr_builder/settings) and open the Media section.
  2. Set Browser type to Media Library and click Save settings. The option appears only when the core Media Library module is enabled. Choose Media Library (Acquia DAM) if you use Acquia DAM.
  3. Go to Structure > Media types and check that a media type with the machine name image exists (video for videos). The builder opens the Media Library on that type.

Note: Basic file upload shows a plain Select image button that uploads straight from your computer. It is the default when Media Library is not enabled. Entity Browser is the legacy option; prefer Media Library.

The upload fails with an error

  • "Destination file path is not writable" or "File could not be saved". The web server cannot write to the files directory. Make sites/default/files writable for the web server user, then check Reports > Status report.
  • "Only files with the following extensions are allowed". The builder accepts GIF, JPEG, PNG, WebP, AVIF and SVG images, and WebM, Ogg and MP4 videos. In the Media Library, the media type decides: add the extension under Allowed file extensions of the image field at Structure > Media types > Image > Manage fields.
  • "exceeding the maximum file size", or "The uploaded video is too large". The file is larger than PHP accepts. Raise upload_max_filesize and post_max_size in PHP, and the body size limit of your web server or proxy.
  • 403 or 405 on /dxpr_builder/ajax/file_upload. A proxy or firewall blocks or redirects POST requests to that path. Allowlist it, and make sure the site does not redirect it, for example from HTTP to HTTPS.
  • Editors get "Access denied" inside the media browser. The role needs View media to open the Media Library, and Image: Create new media to upload in it. Grant both at People > Permissions.

Images vanish a few hours after upload

The file is gone from sites/default/files/dxpr_builder_images and the page shows a broken image.

Releases before 3.0.0-alpha85 saved builder uploads as temporary files when the Media module was off. Drupal's cron deletes temporary files after six hours.

  1. Update to the current release. It saves uploads as permanent files and records their usage.
  2. Upload the missing images again, or restore them from a backup into the same folder.

Note: uploads go to dxpr_builder_images, dxpr_builder_videos and dxpr_builder_files in the default files directory.

Images show in the editor but not for visitors

  • The image is gone after a reload. The container was not saved. Add the image again and click Save on the container bar.
  • You see the image, visitors do not. Apply text format filters to frontend content is on under General Settings > Text Filters, and the field's text format removes img tags or their attributes. Editors always see the unfiltered content. Turn the setting off, or allow img in that text format.
  • Visitors see an older version of the page. A cache serves the old page. See Visitors see something different.

Confirm the fix

Upload an image to an Image element and save the container. In a private window the image shows for an anonymous visitor.

What's next?

Media Library integration for reusing existing media in the builder.

Something wrong or missing on this page? Report it or edit the page.