LLMS_Admin_Table::output_tfoot_html()

Output a tfoot element for the table.


Return Return

(void)


Top ↑

Source Source

File: includes/abstracts/abstract.llms.admin.table.php

	public function output_tfoot_html() {
		?>
		<tfoot>
		<tr>
			<th colspan="<?php echo esc_attr( $this->get_columns_count() ); ?>">
				<?php if ( $this->has_resumable_attempts() ) : ?>
					<div class="llms-clear-resumable-attempts">
						<form action="" method="POST">
							<button class="llms-button-primary small" name="llms_quiz_resumable_attempt_action" type="submit" value="llms_clear_resumable_attempts">
								<i class="fa fa-trash-o" aria-hidden="true"></i>
								<?php echo esc_html( __( 'Clear resumable attempts', 'lifterlms' ) ); ?>
							</button>
							<input type="hidden" name="llms_quiz_id" value="<?php echo esc_attr( $this->quiz_id ); ?>">
							<?php wp_nonce_field( 'llms_quiz_attempt_actions', '_llms_quiz_attempt_nonce' ); ?>
						</form>
					</div>
				<?php endif; ?>

				<?php if ( $this->is_exportable ) : ?>
					<div class="llms-table-export">
						<button class="llms-button-primary small" name="llms-table-export">
							<span class="dashicons dashicons-download"></span> <?php esc_html_e( 'Export', 'lifterlms' ); ?>
						</button>
						<?php $this->output_progress_bar_html( 0 ); ?>
						<em><small class="llms-table-export-msg"></small></em>
					</div>
				<?php endif; ?>

				<?php if ( $this->is_paginated ) : ?>
					<div class="llms-table-pagination">
						<?php if ( $this->max_pages ) : ?>
							<span class="llms-table-page-count">
							<?php
								/* translators: %1$d: Current page, %2$d: Total page count. */
								echo esc_html( sprintf( esc_html_x( '%1$d of %2$d', 'pagination', 'lifterlms' ), $this->current_page, $this->max_pages ) );
							?>
							</span>
						<?php endif; ?>
						<?php if ( 1 !== $this->get_current_page() ) : ?>
							<?php if ( $this->max_pages ) : ?>
								<button class="llms-button-primary small" data-page="1" name="llms-table-paging"><span class="dashicons dashicons-arrow-left-alt"></span> <?php esc_html_e( 'First', 'lifterlms' ); ?></button>
							<?php endif; ?>
							<button class="llms-button-primary small" data-page="<?php echo esc_attr( $this->current_page - 1 ); ?>" name="llms-table-paging"><span class="dashicons dashicons-arrow-left-alt2"></span> <?php esc_html_e( 'Back', 'lifterlms' ); ?></button>
						<?php endif; ?>
						<?php if ( ! $this->is_last_page ) : ?>
							<button class="llms-button-primary small" data-page="<?php echo esc_attr( $this->current_page + 1 ); ?>" name="llms-table-paging"><?php esc_html_e( 'Next', 'lifterlms' ); ?> <span class="dashicons dashicons-arrow-right-alt2"></span></button>
							<?php if ( $this->max_pages ) : ?>
								<button class="llms-button-primary small" data-page="<?php echo esc_attr( $this->max_pages ); ?>" name="llms-table-paging"><?php esc_html_e( 'Last', 'lifterlms' ); ?> <span class="dashicons dashicons-arrow-right-alt"></span></button>
							<?php endif; ?>
						<?php endif; ?>
					</div>
				<?php endif; ?>
			</th>
		</tr>
		</tfoot>
		<?php
	}


Top ↑

Changelog Changelog

Changelog
Version Description
7.7.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.