Backward slash instead of forward slash in browserconfig.xml (Windows)

Created on 18 January 2017, about 8 years ago
Updated 27 February 2025, about 1 month ago

I noticed a small issue with the rewriting of the browserconfig.xml file uploaded through the module (in the ZIP file). If the environment is Windows, then the file reads something like this (after rewriting):

<square150x150logo src="\sites\default\files/favicons/mstile-150x150.png"/>

Notice how the src attribute mixes forward and backward slashes? Windows is known for using backward slashes in the paths for its file system, so I'm guessing that's the cause.

By contrast, when uploading the file on a Linux environment, the result is more consistent:

<square150x150logo src="/sites/default/files/favicons/mstile-150x150.png"/>

So I guess the module should test for the presence of backward slashes, and correct it if needed.

🐛 Bug report
Status

Needs review

Version

1.0

Component

Code

Created by

🇨🇭Switzerland s427

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024