You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

34 lines
862B

  1. <?php
  2. use yii\helpers\Html;
  3. /* @var $caption string */
  4. /* @var $values array */
  5. ?>
  6. <h3><?= $caption ?></h3>
  7. <?php if (empty($values)): ?>
  8. <p>Empty.</p>
  9. <?php else: ?>
  10. <div class="table-responsive">
  11. <table class="table table-condensed table-bordered table-striped table-hover" style="table-layout: fixed;">
  12. <thead>
  13. <tr>
  14. <th style="nowrap">Name</th>
  15. <th>Value</th>
  16. </tr>
  17. </thead>
  18. <tbody>
  19. <?php foreach ($values as $name => $value): ?>
  20. <tr>
  21. <th style="white-space: normal"><?= Html::encode($name) ?></th>
  22. <td style="overflow:auto"><?= Html::encode($value) ?></td>
  23. </tr>
  24. <?php endforeach; ?>
  25. </tbody>
  26. </table>
  27. </div>
  28. <?php endif; ?>