How to HTML-encode in the JSP expression language?

后端 未结 1 768
别跟我提以往
别跟我提以往 2020-12-10 11:34

Consider the following piece of JSP:


The value of ${flashVars} conta

相关标签:
1条回答
  • 2020-12-10 12:31

    Use fn:escapeXml().

    <%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
    ...
    <param name="FlashVars" value="${fn:escapeXml(flashVars)}" />
    
    0 讨论(0)
提交回复
热议问题