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

Set up URL escaping for Freemarker #495

Closed
OndraZizka opened this issue Jul 25, 2018 · 1 comment
Closed

Set up URL escaping for Freemarker #495

OndraZizka opened this issue Jul 25, 2018 · 1 comment

Comments

@OndraZizka
Copy link
Contributor

Freemarker can escape URLs, but it needs the default encoding to be set.

${post.uri?url}

To do URL encoding, the framework that encloses FreeMarker must specify the "output_encoding" setting or the "url_escaping_charset" setting, so ask the programmers to set them. Or, as a last chance, you can set the url_encoding_charset setting in the template, e.g. <#setting url_escaping_charset='ISO-8859-1'>, or give the charset explicitly to the built-in, e.g. foo?url('ISO-8859-1').

----
FTL stack trace ("~" means nesting-related):
	- Failed at: ${post.uri?url}  [in template "index.ftl" at line 10, column 34]
@OndraZizka OndraZizka changed the title Set up URL escaping in Freemarker Set up URL escaping for Freemarker Jul 25, 2018
@jonbullock jonbullock added this to the v2.7.0 milestone Mar 7, 2021
@jonbullock jonbullock added this to In progress in v2.7.0 Release May 4, 2021
@jonbullock
Copy link
Member

PR for this #614

@ancho ancho moved this from In progress to Done in v2.7.0 Release May 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

No branches or pull requests

2 participants