Drupal is a registered trademark of Dries Buytaert

duma

1 sites No security coverage
View on drupal.org

Features

Basic Functionality:
DUMA (Direct Upload Media Audio) replaces the standard media field widget with a user-friendly audio upload interface. Users can click to upload audio files directly from content forms and immediately preview them with an HTML5 audio player.

Unique Features:

One-Click Upload: Upload audio files without navigating to the media library
Instant Preview: HTML5 audio player appears immediately after upload for instant playback
Multi-Value Support: Auto-expanding upload slots for fields that accept multiple files
Custom Labels: Upload custom images to replace default upload button text per content type
Drag & Drop Ready: Compatible with Drupal's table drag for reordering audio files
Comprehensive Format Support: MP3, WAV, OGG, Opus, M4A, FLAC, AAC, and WebM
Built-in Protection: File size limits, rate limiting, and MIME type validation
Detailed Admin Panel: Visual overview of which fields use the widget and configuration status

Use Cases:

Podcasting Sites: Content editors upload episode audio directly when creating podcast posts
Music Portfolios: Musicians upload tracks without leaving the artist profile form
Educational Content: Teachers attach audio lessons or pronunciations to course materials
Audio Documentation: Organizations attach voice memos or audio notes to records
Multilingual Sites: Add audio translations or pronunciations alongside text content

When to Use This Module:
Use DUMA when your content editors need a faster, more intuitive way to upload audio files compared to the standard media library workflow. It's especially valuable for sites where audio uploads are frequent and you want to reduce clicks and page loads.

Post-Installation

Initial Configuration (Required):

Go to Configuration → Media → DUMA Settings (/admin/config/media/duma)

Set your media type machine name (default: audio)
Set your source field machine name (default: field_media_audio_file)
Configure maximum file size (default: 50 MB)
Set upload rate limits (default: 60 uploads/minute per user)

Apply Widget to Your Fields:

Navigate to Structure → Content types → [Your Type] → Manage form display
Find your entity reference field that targets media entities
Change the widget dropdown to "Direct Upload Media Audio"
Click the gear icon to configure widget-specific settings
Save the form display

Set Permissions:

Go to People → Permissions (/admin/people/permissions)
Grant "Upload DUMA files" permission to appropriate roles
Typically: authenticated users, content editors, etc.

Optional Configuration:

Custom Label Images: Upload custom images in the DUMA Settings page to replace default upload button text for each content type
Per-Field Settings: Configure different file size limits for individual fields via widget settings

What You'll See:
After configuration, your entity reference fields will display a clickable upload area instead of an autocomplete field. When users upload audio, an HTML5 audio player appears with playback controls, filename, and file size.
Special Considerations:

Ensure your audio media type exists before configuration
Uploaded files are stored in public://duma_uploads/ by default
For private audio files, adjust your media type's file field to use private file system
Clear caches after configuration changes

Additional Requirements

Drupal Core Requirements:

Drupal 11.2 or higher
Media module (core) - enabled
File module (core) - enabled

Media Type Requirements:
You must have an audio media type configured with a file field. Most Drupal installations include a default "Audio" media type, but if not, you'll need to create one:

Go to Structure → Media types → Add media type
Create type with machine name audio (or your preference)
Add a file field (e.g., field_media_audio_file)
Configure allowed extensions: mp3 wav ogg opus m4a flac aac webm

Server Requirements:

PHP fileinfo extension (for MIME type detection)
Sufficient PHP upload limits (upload_max_filesize, post_max_size)
Write permissions for sites/default/files/duma_uploads/

No External Libraries Required:
DUMA is completely self-contained with no external JavaScript libraries or API dependencies.

Audio Processing:

Audio Waveform: Generate waveform visualizations for uploaded audio
Media Entity Audio: Enhanced audio media type with additional metadata fields

Performance & CDN:

CDN: Serve uploaded audio files from a CDN
Advanced CSS/JS Aggregation: Optimize DUMA's JavaScript delivery

Similar projects

Media Library (Drupal Core)

Difference: Requires users to open a modal, browse/upload, then select media. DUMA provides direct inline upload without modal interruption.
Use Core When: You need centralized media management, reusable media across content, or advanced media organization.
Use DUMA When: Audio files are one-off uploads specific to content, or you want faster editor workflow.

DropzoneJS

Difference: General-purpose file uploader for all file types with drag-and-drop interface. Requires external library.
Use DropzoneJS When: You need drag-and-drop for multiple file types (images, documents, etc.)
Use DUMA When: You specifically need audio uploads with instant HTML5 preview and no external dependencies.

IMCE

Difference: File browser/manager with upload capabilities, broader file management focus.
Use IMCE When: You need comprehensive file browsing, organizing, and management.
Use DUMA When: You want streamlined audio-specific upload without file management overhead.

Plupload

Difference: Multi-file uploader with chunked uploads for large files. General-purpose, requires library.
Use Plupload When: You need to upload very large files (100MB+) with chunk support.
Use DUMA When: Standard audio file sizes and you want audio-optimized interface.

Key DUMA Differentiators:

Audio-specific with HTML5 player preview
No external JavaScript libraries
Custom label images per content type
Built-in rate limiting
Multi-value field auto-expansion
Zero configuration for basic use cases

Supporting this Module

DUMA is open-source and free to use. If you find it valuable for your projects, consider contributing:
Ways to Support:

Report Bugs: Help improve stability by reporting issues in the issue queue
Submit Patches: Contribute code improvements and new features
Write Documentation: Share your use cases and configuration tips
Spread the Word: Star the project, write blog posts, or mention it in forums

Issue Queue:
drupal.org/project/issues/duma

Community Documentation

Official Documentation:

README.md - Complete installation and configuration guide

Video Tutorials:
(Coming soon - contributions welcome!)

Getting Help:

Post questions in the issue queue

Contributing Documentation:
If you've written a tutorial, blog post, or created a video about DUMA, please share it in the issue queue so we can add it here!


Part of Direct Upload Media Suite

This module is part of a collection of tools designed to quicken media upload flow:

DUMI
A fast, streamlined way to upload images directly from form.

DUMD
A user-friendly document upload widget for Drupal Media with document preview on node edit forms and content display.

DUMVE:
Remote video and embed video on node edit forms and content display.

Activity

Total releases
2
First release
Dec 2025
Latest release
1 month ago
Release cadence
40 days
Stability
100% stable

Releases

Version Type Release date
1.0.1 Stable Jan 12, 2026
1.0.0 Stable Dec 3, 2025