samedi 25 avril 2015

Merging Cells in Bootstrap Table


I have troubles merging Cells in Bootstrap Table I've found an example here.

But I don't want the merging executed by clicking a button, instead I want to merge automatically.

Here's my code:

<table id='ViewTable'
       data-toggle='table'
       data-url='func/json.php?id=1'
       data-class='table table-hover table-condensed'
       data-striped='true'
       data-show-header='false'>
    <thead>
    <tr>
        <th data-field='picture'></th>
        <th data-field='description'></th>
        <th data-field='value'></th>
    </tr>
    </thead>
    </table>

    <script>
    $(document).ready(function() {
        $('#ViewTable').bootstrapTable('mergeCells', {
                index: 0,
                field: 'picture',
                rowspan: 12
        });
    });
    </script>

Any suggetions?


Aucun commentaire:

Enregistrer un commentaire