Struts2 转义选择值

发布于 2024-09-13 17:54:04 字数 200 浏览 1 评论 0原文

我的选项(使用选择标签)中有多个空格的文本。然后这些空间被转换为一个空间。然后我尝试使用   转义空格,但它随后将其转换为:

 

这不是我想要的。有没有办法在 Strut2 中禁用转义,或者让它始终为我选择的标签转义空格?我可以看到,有一种方法可以关闭属性标签的转义,但不能关闭选择的转义。

I have text in a option (using a select tag) that has multiple spaces. These spaces are then converted into one space. I then tried to escape the spaces with   but it then converts it to:

 

which is not what I want. Is there anyway to disable escaping in Strut2 or have it always escape spaces for me for select tags? There is a way to turn off escapes for property tags but nothing for select, that I can see.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

北渚 2024-09-20 17:54:04

尝试使用属性 escape=false 或 escapeAmp=false

Try with attributes escape=false or escapeAmp=false

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文