我有一个用于同意内容的条款和条件的复选框,并且用户希望标签中链接的条款。我试图做这样的事情:
<s:checkbox name="iagree" fieldValue="true" label="By entering, I acknowledge that I have read, understand, and agree to the
<a href='/rules.pdf'>Official Rules</a>, <a href='/about-us/terms-of-use/'>Terms of Use</a>, and <a href='/about-us/privacy-policy/'>Privacy Policy</a>."/>
不幸的是,JSP 正在转义我的标记,因此您实际上会看到括号、标签等。我可以添加一个属性来确保 HTML 实际用作 HTML 吗?
奇怪的是,我有一个 struts 广播组,它允许标记就好了。