arulrajnet / attila

Pelican version of ghost theme https://github.com/zutrinken/attila
MIT License
173 stars 74 forks source link

Handling backslash in SITEURL and cover image #106

Closed arulrajnet closed 3 weeks ago

arulrajnet commented 2 months ago

Given The SITEURL has the value as https://example.com/ When The cover in article is assets/images/cover.png Then The Generated HTML has the image with // in URL. For ex: https://example.com//assets/images/cover.png

Given The SITEURL has the value as https://example.com/ When The cover in article is /assets/images/cover.png Then The Generated HTML has the image with /// in URL. For ex: https://example.com///assets/images/cover.png

Given The SITEURL has the value as https://example.com When The cover in article is /assets/images/cover.png Then The Generated HTML has the image with // in URL. For ex: https://example.com//assets/images/cover.png

Refer https://github.com/arulrajnet/attila/blob/master/templates/article.html#L10

Handle this for all kind of images in theme.

The workaround