public/wordpress/wp-content/plugins/wp-courseware/includes/legacy/classes/unitfrontend.php
/**
		 * Check if we need to show the answer later button.
		 *
		 * @return Boolean True if yes, false otherwise.
		 */
Check if we need to show the answer later button.
@return Boolean True if yes, false otherwise.
Check if we need to show the answer later button . @return Boolean True if yes false otherwise .
public function check_paging_shouldWeShowAnswerLaterButton() {
			if ( ! $this->unitQuizDetails ) {
				return false;
			}
			$pagingSettings   = maybe_unserialize( $this->unitQuizDetails->quiz_paginate_questions_settings );
			$allowAnswerLater = ( 'on' == WPCW_arrays_getValue( $pagingSettings, 'allow_students_to_answer_later' ) );
			return ( $allowAnswerLater &&
			         (
				         empty( $this->unitQuizProgress ) ||
				          of a quiz retake
				         ( $this->unitQuizProgress->quiz_next_step_type = 'retake_waiting' ) ||
				         ( ! empty( $this->unitQuizProgress ) && $this->unitQuizProgress->quiz_paging_next_q < $this->unitQuizProgress->quiz_question_total )
			         )
			);
		}
public function check_paging_shouldWeShowAnswerLaterButton ( ) { if ( ! $ this -> unitQuizDetails ) { return false ; } $ pagingSettings = maybe_unserialize ( $ this -> unitQuizDetails -> quiz_paginate_questions_settings ) ; $ allowAnswerLater = ( 'on' == WPCW_arrays_getValue ( $ pagingSettings , 'allow_students_to_answer_later' ) ) ; return ( $ allowAnswerLater && ( empty ( $ this -> unitQuizProgress ) || ( $ this -> unitQuizProgress -> quiz_next_step_type = 'retake_waiting' ) || ( ! empty ( $ this -> unitQuizProgress ) && $ this -> unitQuizProgress -> quiz_paging_next_q < $ this -> unitQuizProgress -> quiz_question_total ) ) ) ; }
Check if we need to show the answer later button.
Check if we need to show the answer later button .
// First check if settings allow it. // True if settings allow it, and we're allowed to show it based on what question we're at. // Works on first question // Works on first question of a quiz retake // Works on remaining questions