java - 如何在数据表条目中添加路径

标签 java jquery html datatable liferay

这是我当前的代码片段,用于在 liferay 7 上的数据表中显示数据

 <table id="gbdb" class="table table-bordered table-striped" style="width:100%">
    <thead>
      <tr>
       <th>Name</th>
       <th>Status</th>
       <th>Action</th>
      </tr>
    </thead>
    <tbody>

  <c:forEach items="${guestbookList}" var="guestbook">
       <tr>
       <td>${guestbook.name}</td>
       <td>${guestbook.status}</td>
       <td><a href=/guestbookadminportlet/guestbook_actions.jsp></a></td>
       </tr>
    </c:forEach>

    </tbody>
  </table>

它当前能够显示名称和状态,但我希望引用 jsp 文件中的第三列,该按钮及其功能将位于其中。 我该如何相处??

最佳答案

根据我的理解,您希望在标记的最后一列中显示“guestbook_actions.jsp”文件中的代码。

您可以尝试直接在 td 代码中<%@ include file="file"%>

 <td><%@include file="/guestbookadminportlet/guestbook_actions.jsp" %></td>

关于java - 如何在数据表条目中添加路径,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51018886/

相关文章:

java - 按下保存按钮时保存 Jtable 数据

java - 使用 Apache Commons CLI 获取任意键/值参数

JavaScript - 未捕获的类型错误 : Type error

javascript - 将多个参数传递给 jQuery 函数

html - iOS 邮件客户端不呈现 html 电子邮件

html - 如何将相同的规则应用于 CSS 中的多个选择器

html - 标题中没有填充或边距

java - SessionFactory 给我 java.lang.NullPointerException

java - 反转数字

javascript - 禁用 javascript 中的特定日期