zoukankan      html  css  js  c++  java
  • 动态拼接tr,th

    var dltable='';
    // <c:forEach items="data" var="data" ></c:forEach>
    for(var i=0;i<data.LISTINSPECT.length;i++){
    dltable += "<tr>";
    dltable += "<th style='165px'>";
    dltable += data.LISTINSPECT[i].XZQHNAME;
    dltable += "</th>";
    dltable += "<th>";
    dltable += data.LISTINSPECT[i].YLJC;
    dltable += "</th>";
    dltable += "<th>";
    dltable += data.LISTINSPECT[i].XQZG;
    dltable += "</th>";
    dltable += "<th>";
    dltable += data.LISTINSPECT[i].YT;
    dltable += "</th>";
    dltable += "<th>";
    dltable += data.LISTINSPECT[i].TG;
    dltable += "</th>";
    dltable += "<th>";
    dltable += data.LISTINSPECT[i].TYZD;
    dltable += "</th>";
    dltable += "</tr>";
    }
    var $table = $("#ztblqk1");
    $table.append($(dltable));
     
     
    <!-- 查询结果列表 begin-->
    <div class="result-list">
    <table class="table-result">
    <thead>
    <tr class="tr1">
    <th></th>
    <th width="60px"></th>
    <th width="60px"></th>
    <th width="60px"></th>
    <th width="60px"></th>
    <th width="60px"></th>
    <th width="60px"></th>
    </tr>
    <tr>
    <th class="th1" rowspan="2" style="height: 50px; 50px;">
    <img class="th1-bg" src="<%=basePath %>images/th-bg.png">
    <span class="span1">行政区域</span>
    <span class="span2">类型</span>
    </th>
    <th rowspan="2">移交稽查</th>
    <th rowspan="2">限期整改</th>
    <th rowspan="2">约谈</th>
    <th rowspan="2">通过</th>
    <th rowspan="2">停业整顿</th>
    </tr>
    <tbody id="ztblqk1">
    </tbody>
    </table>
    </div>
  • 相关阅读:
    Unable to load dbxmss.dll (ErrorCode 16). It may be missing from the system Path
    同一网内机器无法连通解决一例
    Day.24
    Day.24
    Day.23
    Day.22
    Day.23
    Day.21
    Day.22
    Day.01-Day.20
  • 原文地址:https://www.cnblogs.com/zhuyeshen/p/10893259.html
Copyright © 2011-2022 走看看