<jsp:param>标签传递中文参数时出现乱码时,请设置request.setCharacterEncoding("具体参数")。
例如:
页面一:jspparam.jsp
<%@ page pageEncoding="GB2312"%>
<%request.setCharacterEncoding("GB2312"); %>
<jsp:forward page="getparam.jsp?country1=中国">
<jsp:param name="country2" value="中国"/>
</jsp:forward>
页面二:getparam.jsp
<%@ page pageEncoding="gb2312" c%>
<%
String country1 = request.getParameter("country1");
String country2 = request.getParameter("country2");
%>
country1 = <%=country1 %>
country2 = <%=country2 %>
<jsp:param>标签传递中文参数时出现乱码
最新推荐文章于 2024-04-20 22:18:43 发布
部署运行你感兴趣的模型镜像
您可能感兴趣的与本文相关的镜像
Stable-Diffusion-3.5
图片生成
Stable-Diffusion
Stable Diffusion 3.5 (SD 3.5) 是由 Stability AI 推出的新一代文本到图像生成模型,相比 3.0 版本,它提升了图像质量、运行速度和硬件效率
4570

被折叠的 条评论
为什么被折叠?



