Activity::more_button()

Description #

Output load more button.

Changelog #

VersionDescription
4.1.2Introduced.

Source #

File: includes/class/class-activity.php

	public function more_button() {
		$paged = max( 1, get_query_var( 'paged' ) );

		$args = wp_json_encode(
			array(
				'ap_ajax_action' => 'more_activities',
				'__nonce'        => wp_create_nonce( 'load_activities' ),
				'paged'          => $this->paged + 1,
			)
		);

		echo '<a href="#" class="ap-btn" apajaxbtn apquery="' . esc_js( $args ) . '">' . esc_attr__( 'Load More', 'anspress-question-answer' ) . '</a>';
	}

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Add your comment