我有网络应用程序。我使用Struts2。我有一点 JSP:
<%@ taglib prefix="s" uri="/struts-tags" %>
<html>
<body>
<s:form action="updateForm">
<s:text name="news.page.main.label"/>
<s:iterator status="stat" value="news">
<table>
<tr>
<td><s:property value="title"/></td>
<td><s:property value="body"/></td>
</tr>
</table>
</s:iterator>
</s:form>
</body>
</html>
此页面有新闻表。例如,我有 2 个用户打开此页面,有时其中一个用户添加了新行。我希望第二个用户的页面例如每 5 分钟更新一次此页面。
如何在 struts2 或 JS 的帮助下做到这一点?
请给出一些代码例如。