3

I have Sitecore User profile pictures saved in Core DB.
In preview mode of a page, the image renders as

http://mysite.org/sitecore/shell/~/media/Profile-Pictures/Demo/author03.ashx?sc_content=core

and is visible.

But the same page when published, renders the image as

http://mysite.org/~/media/Profile-Pictures/Demo/author03.ashx?sc_content=core

and the image is not visible. I also updated the permission to the folder in core DB.

enter image description here

3
  • If you change the image extension in the url from ashx to the image type, does it appears? Mar 11, 2017 at 15:37
  • @HishaamNamooya No it doesn't. It seems like access restriction to core db from a published page. But otherwise, aren't images saved as blob
    – sukesh
    Mar 11, 2017 at 15:48
  • Why saving images to core db? It mostly used for the sitecore cms. You may either use the sitecore content databases (master, web) or filesystem Mar 11, 2017 at 15:51

1 Answer 1

1

The reason why it is not working is that it requires Read access. In order to provide the read access, go to the core database and set the security on the item.

For example, I want to access the media item /sitecore/media library/Experience Profile/Defaults/Channel. So, from the Core database, I navigate to the image or container and apply a read access to the extranet/anonymous or to the specific user.

enter image description here

UPDATE

From the screenshot you provided, you have set the access to the default\Anonymous user. You need to set it on the extranet\Anonymous.

  • Go to the User Manager and select the extranet\Anonymous

enter image description here

  • Once selected, click on the Security Editor and set the Read access. An example is shown below:

enter image description here

6
  • That did not work. I assigned the permissions as said and also uploaded the new pic.
    – sukesh
    Mar 12, 2017 at 9:53
  • Can you please share some screenshots of the security editor Mar 12, 2017 at 10:39
  • I updated one in question. Please let me know if you need any other
    – sukesh
    Mar 12, 2017 at 12:41
  • @Qwerty, I have updated the answer. Please see the Update section Mar 12, 2017 at 12:52
  • That worked!!!. Thank you Hishaam. For anyone, who are experiencing the same issue, no need to append "/sitecore/shell". The image src renders differently for preview mode and live mode and it will still work.
    – sukesh
    Mar 12, 2017 at 13:09

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.