Questions tagged [files]

Use it to generally reference to those files used on websites which could be video, images, pdfs, etc.

688 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
6
votes
1answer
834 views

Upload multiple files through a single file dialog?

In a Webform, I want to let the user upload multiple files via one call of the file dialog. I found the following modules. Webform Multiple File Upload Webform Multiple File With either of them, I ...
6
votes
2answers
2k views

Reasons for subsequent Broken/missing handler in Views?

In the process of upgrading Drupal 6.x to 7.x I'm facing a problem that makes all my views show nothing relevant. (I believe the problem is here but I'm not sure, I don't know. That's why I'm asking): ...
5
votes
2answers
2k views

Displaying the contents of a document file (doc, docx, etc.)

I'm looking for a way to display the contents of an uploaded document file such as a .docx file. In Drupal 6 I used the iPaper module which did the trick as all I needed was api code to connect ...
4
votes
0answers
276 views

Image styles are not generated in Docker for Windows

When I open in browser http://localhost:1567/sites/default/files/styles/thumbnail/public/2017-10/478069720_1384178114_4.jpg, I see 404. The "original" images are uploaded successfully, and the ...
4
votes
2answers
348 views

Detect when 'Remove' is clicked on a file widget form element?

I have a handful of file fields that have the following default Drupal behavior: User can upload a file User can upload another file in place User can remove file Standard config. Whats happening is ...
4
votes
2answers
1k views

How to select files from /sites/default/files with IMCE filebrowser?

Somehow the settings of directories in the configuration of IMCE (7.x-1.7) is pointing to <root>/. which lets met start in the private_files directory but not in the (public) files directory. I ...
4
votes
2answers
1k views

Upload file and fill in fields in one step; or trigger a rule when a file is uploaded

I want to make use of the Media module and the File entity module to upload files, in particular images, to my site without having to attach them to a node. Solely uploading images works like a charm, ...
3
votes
0answers
77 views

How do I use hook_entity_access() to let anonymous users upload private files?

I have same issue described in How to skip the ReferenceAccess constraint on a file upload by an anonymous user? So I need to use hook_entity_access() or hook_ENTITY_TYPE_access() to solve the issue. ...
3
votes
1answer
164 views

How do I utilize Drupal commerce to sell large files stored on Amazon S3

I am working on a project for work that involves replacing a current "tape and staple" file delivery system. It's a Drupal site, but with many many third party outdated VERY unstable software. However,...
3
votes
1answer
249 views

Drupal prevents file save on chunked upload because of php.ini max upload size

I'm encountering a tricky problem with my custom file widget (which extends the core file widget). It chunks files so that I don't have to raise upload_max_filesize and post_max_size in php.ini, and ...
3
votes
0answers
618 views

Error saving custom field type module with “managed_file”

I have created a custom field type module (field plugin) containing four fields: title, description, address, image. Drupal version: 8.02 This is the schema structure inside FieldType php file: ...
3
votes
0answers
321 views

Is there any way to add a file field for multiple upload file to a custom form?

I'd like to add a file upload widget to a custom form, with core file module, as shown in the admin edit node page. I've trying with the 'managed_file' API, but I've only got upload one file. I need ...
3
votes
0answers
736 views

Unzip a file in Drupal 7 Form API and upload extracted files

I'm creating a custom form using Drupal 7 Form API, and I need my users to be able to select a ZIP file containing a number of other files. I'd like to be able to extract the files and then upload ...
3
votes
2answers
724 views

How to scan a directory to list all sub folders not files

I have a folder (root folder) with thousands of sub folders and *.json files inside sub folders. How can I get list of sub folder names inside folder (root folder) using file_scan_directory?
3
votes
0answers
4k views

“View private files” permission not effective

I have 3 users, an administrator, an uploader, and a viewer. The uploader has a file field attached to his profile and the destination folder of the uploaded (in my case .pdf) file is set to the ...
3
votes
0answers
681 views

How to pipe file uploads to subdomain?

I've got a Drupal 7 site on Apache and Varnish, sitting behind the CloudFlare CDN. Everythin on mysite.com goes through cloudflare... I also have a "direct access" subdomain set up at direct.mysite....
3
votes
1answer
260 views

How can I generate commerce file audio preview automatically?

In a store of music files with the Commerce File module, how can I generate an audio preview of that file? Would be perfect if I could use the Rules module for detect the adding of file and SOX ...
2
votes
0answers
101 views

How can I create an alias to point to an uploaded file?

Users uploading a file within content create a name like my_site.com/sites/default/files/import/CrazyLongNamefile.pdf They would like to alias it for referencing in other media (print) like my_site....
2
votes
0answers
277 views

How capture video thumbnail , when video is uploaded under media video type file?

I'm using Core media module to upload video[Media Type is video,which has field video of 'file field type']. This module will refer video.png as thumnail for all video uploaded from the local system. ...
2
votes
0answers
675 views

Drupal 8 Private file is accessbile by anonymous user

I have created a content type with file field and set Upload destination is private files. I have also set the $settings['file_private_path'] = '/path/to/private'. But the file is accessible by ...
2
votes
0answers
490 views

How do I add an #ajax callback to File field form widget?

I have a content type with a file field: field_file_field . I want to attach a custom #ajax callback to the widget which will execute after file upload. I have tried with: $ajax_settings = array( ...
2
votes
1answer
309 views

How to get an export option as a pdf for views?

I am using views on my Drupal site I can able to export my view in csv, but I am not able export my views as pdf I need to export my view as pdf. Any suggestions on this it will be very helpful, ...
2
votes
0answers
151 views

wysiwyg module and imce missing upload button

I am attaching an image....i have wysiwyg module with cke library and also imce module and imce bridge module. When I click browse to upload images, i get a nonfunctioning screen....It does not work ...
2
votes
0answers
62 views

Using Views without Database Support

We build a Drupal 8 based content management system that uses a triple store as the main data back-end. So we don't have any content data in Database tables. All CRUD operations on entities stored ...
2
votes
1answer
2k views

How to rename uploaded files

Using Drupal 8, I want to rename and clean all filenames, e.g. If someone uploads file named like this Screen Shot 2016-03-29 at 1.13.21 PM.jpg, I want to clean it so that convert all spaces to dashes ...
2
votes
0answers
68 views

Private files broken

I just moved a site to another server (Windows IIS 8.5). Public images are working perfectly, but private images seem to be broken. By having a look at the browser's inspector, I can see that when I ...
2
votes
1answer
838 views

How do I integrate media (e.g. attaching audio) to nodes?

I installed the Media Entity module for Drupal 8. I thought it would somehow facilitate adding Mp3, etc, as Media does in Drupal 7, where I could specify a media player type for an audio file. (And ...
2
votes
0answers
25 views

Getting a node-uniqe identifier such as node id or path as replacement pattern at node creation

I have a content type which consists of a large text field and a number of file fields. Users are allowed to /node/add instances of this content type and are then expected to upload all relevant files ...
2
votes
0answers
880 views

How to upload my video using Video module and CKEditor?

I'm trying to upload my custom videos to my Drupal 7.28 site. I want to add videos in my most of the posts or pages. I've installed the Video module and also have CKEditor module working. Is there ...
2
votes
0answers
63 views

Add a confirmation step on file upload

I'm trying to add a confirmation step when I upload a file (file_entity). After I upload a file that exists already on the server, I want the user to be asked if he really wants to replace the ...
2
votes
1answer
109 views

How handle large number of images in gallery node Drupal 7

I have some gallery nodes with a large number of images (100+), the upload with Plupload integration module works fine, but after save the node and edit it again the node edit form loads 20+ seconds! ...
2
votes
1answer
270 views

How to hide path location in drupal 7?

How to hide path file in drupal? Now it looks like this: http://localhost/drupal/sites/default/files/document.pdf I want to change to look something like this: http://localhost/drupal/media/view....
2
votes
0answers
191 views

Entityform send uploaded files as link and not as an email attachment

I am using Entityform to send email notification to admin when visitors submit a form with an uploaded PDF file. How do you get the uploaded file to be provided as an email attachment and not as link?
2
votes
2answers
685 views

How can I attach multiple pdfs to drupal_mail() function?

Was doing something like this global $base_url; $uri = $base_url . '/sites/default/files/test.pdf'; if(!empty($mail_content)) { /*send mail */ $to =$...
2
votes
1answer
211 views

How to Make File Description Field Required?

Use case: Users who are authorized to use the edit page are required To upload at least one file Must have an associated description with the file. Plus: How can I edit "Description" to display "...
2
votes
0answers
33 views

Thumbnail directory name

I'm creating a video hosting website, the thumbnails are uploaded manually, because i couldn't configure ffmpeg because of shared hosting. I would like to retrieve a videos thumbnail from the server, ...
2
votes
1answer
124 views

Unique file system for multiple domains in Domain Access

I have created five domains using domain access module like test1.com test2.com test3.com etc, Now i want each users from different domains have to use unique file system in order to upload media. ...
2
votes
0answers
431 views

How to populate a managed file field with ajax

Problem I have a large form with a select field tied to an ajax call. When an option is selected a large chunk of the form is rebuilt and a number of fields re-populate. All the fields pre-populate ...
2
votes
0answers
260 views

Video Embed Field module - how do I add attribute 'id' to the embed youtube iframe?

The question is related to DRUPAL modules name is 'Video Embed Field' module. The default output of this module generated the Youtube iframe embed as set in the config by Administrator. But... The ...
2
votes
0answers
59 views

“managed_file” type element not showing in my custom block configure form

I have been creating a portfolio section for my one page theme and I created a module for these section blocks. Now, I'm using the hook_block_configure to set the data into the blocks. Only 1 "#...
2
votes
1answer
178 views

FieldCollection/PLUpload - Recurring error when uploading images on PROD - “No file by that name exists”

TL;DR Pantheon's distributed file system can't handle modules that refer to the temp file system across multiple requests, which messes up the Plupload module. What alternatives are there? The error ...
2
votes
0answers
136 views

Default file upload for a field created in content type

In Drupal7 we have an option to upload an "default image" while creating a "Image field" in content type. Likewise, I need to know is there is any option to add default "pdf or text file" for "File ...
2
votes
0answers
82 views

Problem with “drupal_add_js”: Conflicts ShareBar module with IMCE popup

I have installed ShareBar module (https://www.drupal.org/project/sharebar) at my drupal 7 site. Unfortunately it caused that on IMCE popup (when we can upload images) doesn't appear buttons for files ...
2
votes
1answer
780 views

How to show list & thumbnail widget in plupload?

I have installed the following modules: FileField Sources Plupload, FileField Sources, Plupload module and added latest plupload library. While uploading multiple files it is showing only list of ...
2
votes
0answers
105 views

Video Embed Field: Pull in Original Title & Description

I'm using the video embed field in Drupal 7. I'd like to pull in the original title/description from youtube/vimeo, and then have an (optional) additional user description field. How do I get it to ...
2
votes
2answers
32 views

filefiles node and comment in one view

I have a content type called "Document" where i have a "file" field so i can upload files. I also have comments enable where another users can add a comment and also upload more files. Whats i would ...
2
votes
0answers
552 views

Colorbox You tube video

I am using Youtube module and colorbox. I have a content type with a youtube thumbnail in the teaser. If you click on it, I would like it to open in a colorbox with dimensions 420x315. Instead it ...
2
votes
0answers
180 views

ckeditor or drupal keeps adding closing source tag /> at the end of <source> tag. Using Video Plugin for ckeditor

I am using the ckeditor for drupal and the video plugin for it to embed video's to site. I have tried to edit the Video plugin javascript file like below so it will spit out something like this <...
2
votes
0answers
41 views

Bad experience: PDF to ImageField and similar Drupal modules

I can not make them work (PDF to ImageField, PDF Preview and PDFThumb), No errors, no status report messages. Simply it doesn't show the preview as it should.
2
votes
1answer
829 views

Unable to set file upload destination private when programmatically creating new content type with file field

I am creating a module to upload video to an in house media converter - as part of the module installation I create a new content type called "user video" which has a file field as part of it. I need ...