We're evolving to serve you better! This current forum has transitioned to read-only mode. For new discussions, support, and engagement, we've moved to GitHub Discussions.
It seems that you are using relative URLs, that’s why you get that dot at the beginning.
The only solution is to create a custom helper which will get url as an argument and will remove the dot. Example custom helpers are described here: https://getpublii.com/dev/tags/custom-helpers/
It seems that you are using relative URLs, that’s why you get that dot at the beginning.
The only solution is to create a custom helper which will get url as an argument and will remove the dot. Example custom helpers are described here: https://getpublii.com/dev/tags/custom-helpers/
let themeHelpers = { removeDot: function(url) { if (url[0] === ‘.’) { return url.substr(1); } return url; } }; module.exports = themeHelpers; and then you can use:
{{removeDot url}}
Hi,
Thank you for your reply.
I have tried your method. it would take ” PUBLII_RELATIVE_URL_BASE#/xxx.html ” instead of “.”.
and how to achive this if the url is not relative?