public/wordpress/wp-content/plugins/wp-courseware/includes/legacy/quiz/truefalse.php
/**
		 * Extract the correct answer for a True/False question, using the specified answer key to check $_POST.
		 *
		 * @param String $correctAnswerKey The key to use to extract a correct answer.
		 *
		 * @return String The correct answer, if it was found.
		 */
Extract the correct answer for a True/False question, using the specified answer key to check $_POST.
@param String $correctAnswerKey The key to use to extract a correct answer.

@return String The correct answer, if it was found.
Extract the correct answer for a True / False question using the specified answer key to check $_POST . @param String $correctAnswerKey The key to use to extract a correct answer . @return String The correct answer if it was found .
public static function editSave_extractCorrectAnswer( $correctAnswerKey ) {
			if ( isset( $_POST[ $correctAnswerKey ] ) && in_array( $_POST[ $correctAnswerKey ], array( 'true', 'false' ) ) ) {
				return $_POST[ $correctAnswerKey ];
			}
			return false;
		}
public static function editSave_extractCorrectAnswer ( $ correctAnswerKey ) { if ( isset ( $ _POST [ $ correctAnswerKey ] ) && in_array ( $ _POST [ $ correctAnswerKey ] , array ( 'true' , 'false' ) ) ) { return $ _POST [ $ correctAnswerKey ] ; } return false ; }
Extract the correct answer for a True/False question, using the specified answer key to check $_POST.
Extract the correct answer for a True / False question using the specified answer key to check $_POST .
// Expecting a string of 'true' or 'false'. // Not found, so returning '' (empty string).