getattachment .net core not working with paremeters

lawrence whittemore asked on July 6, 2023 19:04

sometimes we add parameters to a getattachment url to resize an image. something like this

getattachment/{Guuid here}/file-name.png?width=90

it appears that a recent update to kentico 13 has stopped this from working. it still works properly if I run it from the admin.

admin/getattachment/{Guuid here}/file-name.png?width=90

Is there a way we can resize the image on load now?

Correct Answer

lawrence whittemore answered on July 12, 2023 14:21

Looks like there was a DLL that changed and was missed when I pushed out the update.

0 votesVote for this answer Unmark Correct answer

Recent Answers

Brenden Kehren answered on July 6, 2023 19:26

Honestly, I'd highly recommend NOT using attachments at all. It won't be supported in future versions. Change them over to media files or a page type with a reference to a media file.

I know this doesn't fix your problem, but something to work for in the upcoming months.

0 votesVote for this answer Mark as a Correct answer

Juraj Ondrus answered on July 10, 2023 08:53

Could you please provide steps how to reproduce the issue? I just tried it and it works fine. Maybe I am missing something - I do not know at least where and how are you inserting the attachment links. Also, what is the exact version, hotfix you are using, please?

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.