Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [media-library]

Anything related to media stored in the database or file system and created as items in the Media Library.

0
votes
0answers
13 views

Set CDN Media.AlwaysIncludeServerUrl to FALSE when user is in Experience Editor mode

I use the following configuration for setting the CDN prefix for media files in my sitecore. But when viewing a page within the experience editor, none of the images can be reached by the CMS as the ...
0
votes
0answers
18 views

Media Library Items: can I specify a path that is relative from the “Media.FileFolder” setting?

When I use the file system to store items from the Media Library, I can see that each item stores either an absolute path or one that is relative from the webroot - not a path that is relative from ...
6
votes
1answer
105 views

Upload Files (Advanced) randomly removing dashes

I'm working on a SPE script that uses the standard media library upload tool to take a file then uses the built in unzipper to unzip it. Upon unzipping the media items sometimes it removes dashes from ...
0
votes
0answers
42 views

Faking a MediaRequest and Media Items

I am currently trying to mock a media request and the media item I am requesting using FakeDb but for some reason my request is returning an empty MediaPath rather than the MediaPath I am expecting. ...
1
vote
1answer
25 views

Run MediaRequestHandler after Session_Start for authentication purposes

The media library images in our solution are protected by a custom override on the Sitecore MediaRequestHandler. This, in turn, checks against some Sitecore configuration item whether or not a user is ...
1
vote
0answers
29 views

Could not save posted file exception while uploading an image to media library that ends with (number).extension

When I upload an image to media library that ends with (number).extension Sitecore gives an error - log looks like below. No error if it ends with just () or (letter) or if (number) has a letter ...
5
votes
0answers
34 views

Transparent PNGs lose transparency when uploaded to media library (8.2)

I have some PNGs that I created in Photoshop which have transparent backgrounds. I've saved these as PNGs and when I view the images in my file stystem in my browser, the background is transparent as ...
4
votes
1answer
22 views

Content editors get access denied when attaching new language version to a media item

Our content editors get an error when they try to upload a new version of a document (or any other media item). Steps they take: Go to media library Upload a file (with advanced options) as versioned ...
1
vote
0answers
58 views

Custom parameters in media URL query string - Sitecore render method/pipeline

I am using Sitecore's render method to construct the query strings for image assets, but I have a small challenge parsing custom parameters into the rendered query string in the HTML. It seems that ...
2
votes
1answer
50 views

WebP format support with back word compatibility (support in IE, Safari)

I am using Dianoga module (Thanks to Kam Figy) to optimize the images. At present looking to enable WebP format with backward compatibility (serving default image format for un-supported browsers) ...
3
votes
1answer
33 views

What are the side effects of disabling Sitecore.Analytics.Media.MediaRequestEventHandler?

Our load tests have shown that the Sitecore.Analytics.Media.MediaRequestEventHandler reduces load time of media assets by a certain factor. If we were to disable this handler, what functionality ...
1
vote
1answer
39 views

Calculating dianoga's optimized image size?

Is there a way to programmatically get the Sitecore media files' size which is being optimized by Dianoga? We need to show the image size on the site. MediaItem.Size property is getting us the ...
1
vote
2answers
94 views

Images throwing 404 on staging but not live

Strange problem that's started happening recently. I have an instance of sitecore 8.0 setup (CD and CM separate servers). A user uploads an image. (stored as blobs in the db) It shows in experience ...
2
votes
2answers
79 views

How to restrict uploading of certain media files to Sitecore? [duplicate]

I am new to Sitecore and not sure how to restrict certain files from being uploaded to the Media Library. Let's say we do not want users to upload pdf files to Sitecore; how would you do that? Write ...
1
vote
0answers
46 views

Media items not appearing on website after deployment

We are facing an issue with media library during our deployment using Octopus. We have a publish site step in the deployment steps. The issue is media items are not showing in the website after the ...
4
votes
2answers
111 views

Uploading zip file to Media Library and enabling “unpacking” results in an error

The issue When I use the Upload files (advanced) feature of the Media Library to upload a zip file with images in it (Sitecore 8.1 Update 3) and check the box to Unpack ZIP archives, uploading fails ...
2
votes
1answer
21 views

Sitecore FileUtil.ZipFiles creating zip files from Media Library items

Is it possible to create a zip file using Sitecore FileUtil.ZipFiles where the files to be added are from the Media Library items?
1
vote
1answer
82 views

Can't add image to the sellable item

We are using Sitecore 9 Update 2 + Sitecore Commerce 9 Update 2. Search field didn't return any result when I'm trying to add an image to the sellable item. As a key, I use image name. Before that, ...
3
votes
1answer
93 views

Will Sitecore support Jpeg 2000 , Jpeg XR, webp image format by default?

We have recommendation from our seo team to use image format like jpeg 2000, jpeg XR, webp but when we try to upload Jpeg 2000 image with extension .jp2, sitecore not taking as image format instead it ...
0
votes
2answers
65 views

Get Optimized Image in sitecore

I am using below setting in my application to reduce file size, but no luck. Sometimes it is giving bigger than the original size. Media.UseLegacyResizing -> value=true Media.InterpolationMode -> ...
1
vote
2answers
66 views

How to make a media library image searchable with few keywords rather just the item name?

Simply wondering how to tag an image with a few different keywords and find it that way later on within the media library. It seems like currently the search function of the media library only picks ...
1
vote
0answers
121 views

Download Sitecore Media file from UI

In our application we have an excel (xlsx/xls) file in medial library. We are trying to create a functionality to be able to download this excel using an html anchor or button. But when we click on ...
6
votes
1answer
81 views

Media file path based vulnerablity

During a vulnerability scan, Path-Based Vulnerability has been reported in the below-mentioned links, www.sample.com/web/abcdefgh/ijklmnop/-/document_library_display.old www.sample.com/web/abcdefgh/...
2
votes
1answer
81 views

Updating Media Item Stream on Item:Saved Event

I had implemented a item:saved event handler that updates the MediaStream of a MediaItem. The code is roughly like this: public void OnItemSaved(object sender, EventArgs args) { ...
1
vote
1answer
78 views

Title label is missing in Image Properties - Sitecore Media Image

In my application when editing, image properties from a rich text editor the label is missing for "Title". (Ref. Image) Anybody having an idea of where to configure the label? Thanks in advance
3
votes
0answers
49 views

ShowFieldEditor on a media item detaching media

I have a simple script that we're running, where a content editor has bulk uploaded media and they want to go back through and provide attribution to the images (caption, alt text, photo credit) and ...
2
votes
0answers
50 views

Encrypt zip file while uploading to media library folder sitecore 8.2

i have followed the sitecore link and create my custom processor for (Sitecore.Pipelines.Upload.Save). i have faced issues while saving all media items. it gives error on file.SaveAs(filename); ...
7
votes
1answer
134 views

SPE How to add multiple items to package source

I'm writing a SPE script to package up all unused media library items under a specific folder (prior to deletion). I've found New-Package and New-ItemSource methods and know how to use them (to some ...
2
votes
0answers
57 views

How to set Media Cache Folder per site?

Context In my Sitecore (8.2.u7) instance I have 2 websites that share the same images. For this reason, I have setup Media.MediaLinkServerUrl e.g. cdn.mysite.com. This will also help me to integrate ...
5
votes
1answer
270 views

How to display PDF link in Sitecore page

I'm using Sitecore 9 and SXA 1.7. I have a few PDF files that I have uploaded into media library/files/myfolder, and an "instructions" template whose fields are title (type: single line text), Date (...
3
votes
1answer
28 views

Uploading media from Image field is uploading as versioned

In sitecore 8.2 update 4, when we are uploading image from image field on item, media template is versioned type but when we are directly uploading image in media library then media template is ...
4
votes
2answers
580 views

Why does MediaManager.GetMediaUrl() return internal “/sitecore/shell/-/media” URL instead of “~/media” URL?

I'm programatically inserting some JPGs into the Media Library with the MediaCreator and then putting URLs to those images in a Rich Text field another item (page). When I call MediaManager....
0
votes
1answer
52 views

Sitecore media protection | outside sitecore application

Has anyone tried to protect media assets(with hash) outside sitecore application ? For example if a request comes for a sitecore media url, you need to create a separate application(say a webapi) , ...
1
vote
1answer
255 views

Error when selecting an image in Media library

I'm facing an issue where when I'm in the content editor clicking on some already uploaded images in the media library, then I get a popup with an error in it. And when I go to the event viewer to ...
0
votes
1answer
54 views

Convert files to PDF when uploading to media library

Is there any built-in mechanism to convert files to PDFs when uploading them to the media library, or does someone know of functionality that can accomplish same?
3
votes
1answer
97 views

Using SXA's “Gallery” component to view all images under “media library” automatically

I am Using SXA 1.6, my question is about the gallery component. I need the gallery component to be able to view all the images under "media library", and not be restricted to a component of type "...
0
votes
1answer
155 views

Sitecore Media File upload above 2GB throws Bad Request 400

we are on Sitecore 8.1 U3 , content editors generally upload large files to the media library using the File upload (advanced) option with Upload as files checked , these files are uploaded to a blob ...
0
votes
0answers
24 views

How to display image in sitecore [duplicate]

How to render a responsive image in the Sitecore? I have an image of size 1200 px have to display the image in thumbnail size.is it possible to do it in Sitecore? Any example or sample is much ...
0
votes
1answer
40 views

Sitecore 8.2 multilingual versioned media item per site [closed]

I have a certain site on a Sitecore instance with 3 sites. One of them must become multilanguage, where the content tree is done already. But the media items under the media library cannot be easily ...
0
votes
1answer
514 views

I have image path into media library, how I can show it into cshtml?

My model contains string property ImagePath with media file path, for example: "/sitecore/media library/Comp_Images/Division1/Client1/Client_Images/BobRoss.jpg" How can I display it into cshtml in ...
0
votes
1answer
125 views

Pipeline For Media Library for CD

I'm new to Sitecore and I'm looking for the details of media library pipelines in CD. I'm trying to redirect media library link based on a flag. If the flag is checked for media library item then it ...
0
votes
1answer
131 views

Sitecore Forms Submit Action redirect to a PDF in Media Library

I have a form that, upon submission, should redirect and display a PDF from my media library. Upon submission, I am receiving this error: Does Sitecore 9 Forms require that I provide a layout file ...
1
vote
0answers
118 views

Media item (image) and RTE

I'm running into an issue with using images in RTE. Images upload as expected into the medialibrary so no issues there. But when I insert the newly uploaded image in RTE it'll appear in Experience ...
1
vote
1answer
125 views

Restricting selection to a specific folder for use as an image file

The requirement is to have an image field that is not the standard one but rather a pulldown list of images from a specific folder. I can get this to work on the backend by using a droplist field or ...
3
votes
2answers
285 views

Media Item not created in multiple languages

We have problem with uploaded media item in Sitecore 9. When we are uploading some media file (image, video etc.), it will be created only in default language and not in all languages. This worked in ...
1
vote
2answers
150 views

Chrome icon coming for pdf's in media library instead of PDF icon

When I tried to upload a pdf file in Media library I am getting chrome symbol as icon instead of pdf icon. I tried in vanilla instance where everything works fine. I checked the template's icon and it ...
0
votes
3answers
553 views

Inserting SVG files/markup

There seems to be an issue with SVG markup that works fine when embedded manually (through a rich text field for example) vs. when I save that same code as an .svg file, add it to the media library, ...
1
vote
1answer
115 views

How to change template for multiple items

There are many PDF files in our project that are manually added to the media library. I see that some of them have the template - /sitecore/templates/System/Media/Versioned/Pdf and some others - /...
2
votes
0answers
124 views

Video Media item is not loading as per language query string parameter?

I have created media item and uploaded two different video in "English" and "Spanish" version. When accessing this media item, it is not loading the video as per the query string parameter, please ...
2
votes
2answers
352 views

How to correctly login as Virtual User to use the Sitecore Content Editor? (Avoid Media Library Search redirects)

I have a situation where I need to use VirtualLogin to enable a user to access the sitecore shell and use the Content Editor / Media Library editor. This is the code for the Virtual Login (from many ...