LLMS_Metabox_Table_Field::output()
outputs the Html for the given field
Contents
Return Return
(void)
Source Source
File: includes/admin/post-types/meta-boxes/fields/llms.class.meta.box.table.php
public function output() {
global $post;
parent::output(); ?>
<table class="llms-table zebra text-left">
<thead>
<?php foreach ( $this->field['titles'] as $title ) : ?>
<th><?php echo wp_kses_post( $title ); ?></th>
<?php endforeach; ?>
</thead>
<tbody>
<?php if ( $this->field['table_data'] ) : ?>
<?php foreach ( $this->field['table_data'] as $row ) : ?>
<tr>
<?php foreach ( $row as $column ) : ?>
<td><?php echo wp_kses_post( $column ); ?></td>
<?php endforeach; ?>
</tr>
<?php endforeach; ?>
<?php elseif ( $this->field['empty_message'] ) : ?>
<tr>
<td colspan="<?php count( $this->field['titles'] ); ?>">
<?php echo wp_kses_post( $this->field['empty_message'] ); ?>
</td>
</tr>
<?php endif; ?>
</tbody>
</table>
<?php
parent::close_output();
}
Expand full source code Collapse full source code View on GitHub