Alert: This function’s access is marked private. This means it is not intended for use by plugin or theme developers, only in other core functions. It is listed here for completeness.

LLMS_Table_Achievements::get_actions_html( $achievement_id )

Get HTML for buttons in the actions cell of the table


Description Description


Parameters Parameters

$certificate_id

(int) (Required) WP Post ID of the llms_my_certificate


Top ↑

Return Return

(void)


Top ↑

Source Source

File: includes/admin/reporting/tables/llms.table.achievements.php

	private function get_actions_html( $achievement_id ) {
		ob_start();
		?>
		<form action="" method="POST" style="display:inline;">

			<button type="submit" class="llms-button-danger small" id="llms_delete_achievement" name="llms_delete_achievement">
				<?php _e( 'Delete', 'lifterlms' ); ?>
				<i class="fa fa-trash" aria-hidden="true"></i>
			</button>

			<input type="hidden" name="achievement_id" value="<?php echo absint( $achievement_id ); ?>">
			<?php wp_nonce_field( 'llms-achievement-actions', '_llms_achievement_actions_nonce' ); ?>

		</form>

		<script>document.getElementById( 'llms_delete_achievement' ).onclick = function( e ) {
			return window.confirm( '<?php esc_attr_e( 'Are you sure you want to delete this achievement? This action cannot be undone!', 'lifterlms' ); ?>' );
		};</script>
		<?php
		return ob_get_clean();
	}

Top ↑

Changelog Changelog

Changelog
Version Description
3.18.0 Introduced.


Top ↑

User Contributed Notes User Contributed Notes

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





Permalink: