【问题标题】:Errors reporting on JSP using Struts tags使用 Struts 标记在 JSP 上报告错误
【发布时间】:2013-08-26 03:03:27
【问题描述】:

我使用 struts 和 ibatis 创建了一个小型登录应用程序。一切正常。 验证错误显示在我的 JSP 页面中。 <html:errors> 标记在组中的一个位置显示所有错误。

我想在与特定错误相关的每个 html 元素前面显示错误。

有没有像<html:error name="username" />这样的标签

请指教

【问题讨论】:

    标签: struts


    【解决方案1】:

    <html:errors> 标签和<html:messages> 标签都是这样做的(以不同的方式)。阅读their documentation

    【讨论】:

      猜你喜欢
      • 2014-02-10
      • 2019-02-05
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2015-06-02
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多