Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Encoding image URLs for files or folders with a space results in broken image links #31

Open
Imar opened this issue Jun 14, 2024 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@Imar
Copy link
Collaborator

Imar commented Jun 14, 2024

A few templates in Swift (at least Swift_ProductDetailsImage.cshtml and Swift_ProductDetailsGallery.cshtml) use this code;:

string imageLinkPath = Dynamicweb.Context.Current.Server.UrlEncode(imagePath);

The imageLinkPath is then assigned to an href: <a href="@imageLinkPath" ...

When the image URL contains a space, the link ends up broken (the space becomes a +) leading to 404 images. Normally, you don't see these as the link is intercepted by the slider. However, Google and other tools report them as broken links.

Can this be fixed?

Imar

@nicped nicped added the bug Something isn't working label Jun 19, 2024
@nicped
Copy link
Member

nicped commented Jun 19, 2024

Sounds like a bug.

Added a fix here: https://dev.azure.com/dynamicwebsoftware/Dynamicweb/_workitems/edit/20158

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants