您好,登录后才能下订单哦!
密码登录
登录注册
点击 登录注册 即表示同意《亿速云用户服务条款》
引言,我做文章管理的时候,引入的是layui的表格样式,但是里面的内容溢出无法隐藏,后来我采用了往td里面加了个<div></div>
然后设置一下样式就可以了。
<table class="layui-table">
<colgroup>
<col width="100">
<col width="150">
<col>
</colgroup>
<thead>
<tr>
<th>序号</th>
<th>文章标题</th>
<th>文章内容</th>
<th>发布时间</th>
<th>发布人</th>
<th>操作</th>
</tr>
</thead>
<tbody>
<c:forEach items="${pageInfo.list}" var="a">
<tr >
<td class="lid">${a.aId}</td>
<td>${a.aTitle }</td>
<td class="ac" ><div style="width:500px;
overflow:hidden;
white-space:nowrap;
text-overflow:ellipsis;">${a.aContent}</div></td>
<td><fmt:formatDate type="both" dateStyle="long" timeStyle="long" value="${a.aTime}" /></td>
<td>${a.whoRelease}</td>
<td>
<button class="layui-btn-danger layui-btn layui-delete"><i class="layui-icon"></i></button></td>
</tr>
</c:forEach>
</tbody>
</table>
以上这篇layui表格内容溢出的解决方法就是小编分享给大家的全部内容了,希望能给大家一个参考,也希望大家多多支持亿速云。
免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。