Questions tagged [media]

Drupal core has some modules to handle images and other media files, for example the Image module and the Media module.

Filter by
Sorted by
Tagged with
1
vote
1answer
33 views

Missing updates for Media

After much package dependency finagling via composer, updating PHP, updating MariaDb, etc.. (not as bad as D7 => D8 but still harder than I'd hoped) I managed to update from 8.9 => 9.0.7. I was ...
-3
votes
0answers
43 views

How do I create a video embed text filter?

How can I make a filter to get an ID video from a link like the following? {"preview_thumbnail":"/sites/default/files/styles/video_embed_wysiwyg_preview/public/video_thumbnails/J5LdiPsQ-...
0
votes
0answers
75 views

How to create a 'button' which is linked to a Media Document with custom Link text?

I am trying to create the ability for a content editor to add a button to an entity which links to a Media Document. Essentially the requirements are that we can upload a file and that file is ...
0
votes
0answers
50 views

Why is step 2 of file to media migrate giving me missing bundle error?

I am following the instruction on this page : https://www.drupal.org/project/migrate_file_to_media/issues/3118471 , but with media of bundle document, not image. I have my step 1 yml on this issue ...
1
vote
0answers
56 views

CKeditor Media Edit: AJAX HTTP error 500 [closed]

How can I fix the AJAX HTTP error 500 to make the "Edit media" button in the body of the CKeditor work? I am trying to use the "Edit media" function to edit an image, which was ...
0
votes
0answers
29 views

How do I pre-fill a image field in a form with javascript

I've got a form which I want to fill with javascript on a button click. This button click retrieves the data via a javascript call. All regular fields are no issue, I just cant seem to be able to pre-...
0
votes
0answers
21 views

Using Feeds, how to import D7 files and images into a D8 media field

Looking for a method for importing D7 files and images with multiple values into a D8 media field. Any recommendations out there? The official Feeds issue doesn't have much activity and seems to have ...
-2
votes
0answers
18 views

S3FS Media Library

I am using S3 as my default file system. I have an image field in one of the contents. I would like users to be able to browse/reuse the images on S3. Currently, when I select Media Library as the ...
0
votes
1answer
17 views

Trigger Crop API programatically after node is created

Hi I am using Image Widget Crop so that users can crop images according to predefined image styles. All would have worked fine without any issues had I been using Drupal in the conventional '...
0
votes
1answer
31 views

How to create Media video youtube entity programmatically? [closed]

I have file with multiple Youtube URLs such as: https://www.youtube.com/watch?v=asddasOds32 https://www.youtube.com/watch?v=kjh234hknnn https://www.youtube.com/watch?v=iZ53yuirewn ... I need to fill ...
0
votes
1answer
30 views

Deprecated Dependency Warning not removing

In my Drupal 8.9.6 (Installed with Lightning distribution) Status Admin Page, there are three warnings showing after updating several modules and core to the latest versions: DEPRECATED DEPENDENCY: ...
0
votes
1answer
48 views

How can I auto-rotate an image on file upload in a custom form?

I'm using the FAPI to provide the user an upload field for an image. The field is: $form['product_img'] = [ '#type' => 'managed_file', '#description' => 'Upload a PNG or JPG image of the ...
0
votes
1answer
18 views

Link video (media_youtube) to node

I have a content type called 'webtv' for adding videos from youtube with media, media_youtube modules. On the webtv page I want to add blocks with video preview image and node title. My problem is ...
0
votes
1answer
27 views

How to remove images from body field in views?

In the body field of a content type, I have added an image at the start. In my view, I want to show 200 characters from the body field. It also prints the image. How can I skip the photos from the ...
0
votes
0answers
16 views

How do I display media in a colorbox?

The colorbox module functionality is now part of Drupal core media module, that is what i read in the colorbox project page. However, I can't find documentation or guidelines how that actually works. ...
0
votes
1answer
11 views

Programmatically setting video_embed_field URL

I am trying to populate nodes programmatically from a feed (migrating earlier site to Drupal 9). So far I have managed to get everything else to move, but I can't figure out, how to set ...
1
vote
1answer
33 views

How to render text including video embed field

I have a formatted text field, and am using the video_embed module to allow users to embed video into that field, using the video_embed_wysiwyg submodule. I am then trying to render the field in a ...
0
votes
1answer
40 views

Scheduled unpublished content and media that is under content moderation

Let's say you have a need for the following: Content is created with content moderation, with various states. After a set amount of time, the content is deleted or archived. The user can set when ...
0
votes
1answer
31 views

Can't update nodes / node unpublishes itself

This problem has been bugging me for some time now and I haven't been able to find this issue online anywhere else. My Drupal 7 website has a very simple photo gallery, using a custom node type called ...
2
votes
1answer
36 views

How to programmatically create an image style?

I need to create image style programmatically in Drupal 7. I found this issue: https://www.drupal.org/project/drupal/issues/2735969 and much more other issues, but all are for Drupal 8. I can't find ...
0
votes
1answer
15 views

Upload multiple Standolane Media Entities (Images) without Reference Field

I'd like to Upload Images as Media Entities without referencing them in another Entity. In media/add/image I can upload a single Image. That's fine. What I'd like to achieve is a Multiple Upload ...
0
votes
0answers
10 views

Associating form with custom Media source plugin

I need to create a custom Media source plugin to display a CAD drawing from a remote source. In order for me to display the 3-D drawing I need to do three things: Get the part number Load various ...
0
votes
0answers
10 views

default image not showing

I have a entity reference setup in a block that uses the media gallery. I'm trying to get the default image to work which currently if I upload image and it shows but the default image doesn't show if ...
1
vote
0answers
33 views

Show own content in Media Library

I am using Media Library from core, but users can choose media from any user. How can I show own content only? I have tried adding contextual filter in View, but when I change among grid and table ...
0
votes
2answers
39 views

Use url of media field in view twig

I need to output the url for field_slide_media in views-view-unformatted--carousel.html.twig. I can output the entity ID using: {{ view.field.field_slide_media.value(view.result[i]) }} I would like ...
0
votes
1answer
21 views

How do I add multiple images in JSON to meet Google's schema.org requirements?

The Google guidelines for article on schema.org state: For best results, provide multiple high-resolution images (minimum of 300,000 pixels when multiplying width and height) with the following ...
0
votes
0answers
50 views

How do I render an image as SVG?

I want to display an SVG image as SVG code to easily change its color using CSS. I installed the following modules: SVG image, SVG Formatter, SVG image field, SVG Image Responsive, and SVG Sanitizer. ...
0
votes
1answer
20 views

Selector bulk action missing

In the media library, I should see a dropdown selector that allows me to delete bulk items. Is there a way to turn this off and on? I've inherited this site and I'm not sure if the original owner has ...
0
votes
0answers
25 views

Can't remove image from image field on content type

doing some last minute maintenance on a D7 site. Recently needed to change some of the existing content and am finding that I cannot delete images. In clicking the "Remove" button associated with the ...
2
votes
1answer
51 views

How can I track how embedded media is used across my site?

My site uses the core Media module, Entity Embed, and LinkIt to reference media and other entities in various ways. I want to keep track of which media is embedded on which nodes. I tried adding an ...
0
votes
0answers
26 views

video.js module Experiencing an error message after install

I am using Drupal 8 and attempting to set up the video.js module. The readme file needs work so it's hard to know where I went wrong. Here is what I've done so far: installed the module using ...
1
vote
1answer
19 views

How to avoid _0 _1 when editing a media entity and changing the file?

Say I add an image using the built-in Media module. A couple months later, I have to change the image file for some reason. So I edit the media entity, delete the existing file, and upload the new ...
0
votes
0answers
9 views

How select view mode of Remote Video embedded Media for Simplenews display?

When I send out an Article as a Newsletter I want to be able to have any Remote Video embedded in the body of the Article displayed as a link; but when viewed normally in the web page, displayed as a ...
0
votes
1answer
27 views

How to include media documents in search

Is there any way to include documents I created with the media core module into the search form of the page? I only found the categories "users" and "nodes".
2
votes
2answers
189 views

How do I hide the download button on the audio player?

I want to hide the "download" button on the audio player provided by the Media module in Drupal 8. How can I do that?
0
votes
2answers
23 views

How can I manually change image orientation?

I manage a website with Drupal 7 where users can upload pictures from their mobile or from their desktop. I have configured Image Style with "autorotate" effect and most of the pictures are well ...
2
votes
0answers
72 views

Is it possible to use libraries-extend from a module (instead of theme)?

Problem/Motivation I'm interested in altering/overriding the little bit of HTML markup that's output by core, in my case Drupal.theme.mediaEmbedEditButton (from core/modules/media/js/...
0
votes
2answers
58 views

how to display a media description in a twig template?

i want to display the media description available in the file field of a media ( media of type video, audio, image, etc...), it is an option to activate: Enable Description field The description ...
0
votes
0answers
16 views

How to load existing media into media field programmatically

I have a media image called sample.jpg, I want that image to be assigned to a media field called "field_banner_image" by default when I create a node programmatically. I achieved it by using "Media::...
0
votes
0answers
24 views

How to avoid creating duplicate media file while creating media programmatically

In Drupal 8 I am creating a content with media image field, I am using theme preprocessor to attach a default image to the media field (if media field is empty) when new content is created. I used ...
0
votes
0answers
66 views

render different fields of a content type (media) in a twig templates

For the video media type of drupal 8 i want to render the fields of it into a tag. i created the template field--media--video.html.twig copy of field.html.twig i render the field like this : {% ...
0
votes
0answers
22 views

Converting embedded images from Media module to Markdown

My Drupal 8.8 site (media embed is now in core) uses the Markdown module for the Body text of nodes. I created a custom view mode, Ebook export, which has some twig templates that output the raw ...
0
votes
0answers
12 views

Translatable Referenced Entity field as filter for View

I have a multilingual Drupal 8.7.10 site (English and Czech, in this case). Content types Article and Basic Page are translatable and both have some Entity reference field referencing some Media type....
0
votes
0answers
98 views

“Instagram embed” display format (Media Entity Instagram) does not display videos

Trying to configure Media Entity Instagram, following https://drupal-media.gitbooks.io/drupal8-guide/content/modules/media_entity/instagram.html. TL;DR: I have an Instagram media entity getting its ...
0
votes
1answer
26 views

Why are existing entity reference fields not available to add to a media type?

I have a number of existing entity reference fields in my site. The key one is a taxonomy reference field called field_search_terms. I would like to add this field to the Document media type. However ...
1
vote
1answer
169 views

Folder permission errors on public:// after upgrade to 8.8.5

I'm new to this community, and asking for help because I'm stuck on this problem, and cannot go past. I've also tried asking on StackOverflow, but with no luck so far. My current setup: Drupal 8.8.5 ...
0
votes
0answers
22 views

Using Photos Albums and enabling plupload, there's no way to upload

I'm attempting to use photo albums to make a photo gallery. if I don't select the Plupload checkbox for file uploads, when I add content, I have the facility to upload 5 different files. When I select ...
0
votes
2answers
39 views

How do I load a Media entity from a File entity?

I have a File entity loaded programmatically. I want to load a Media entity from it. Is there a way to achieve this?
0
votes
0answers
13 views

Vimeo embed code being ignored

Feeling frustrated. I run an number of websites, and have recently had need to embed video (mostly Vimeo but not exclusively) in one of them. I have another site where I have embedded the code ...
0
votes
0answers
22 views

Is there a way to use the core Media module with an existing image field?

I have a site with a lot of nodes already using an image type field where I'd like to switch to using a Media browser (for consistency with other areas of the site). It seems a media browser can only ...

1
2 3 4 5
54