YaExam 1.0.7 has 100 actions and 105 filters, read directly from its source code on Nov 19, 2026. The list updates automatically when a new version is released.
How to use these hooks
Actions let you run your own code at a specific moment. Filters let you change a value before the plugin uses it. Put your code in a child theme's functions.php or a code-snippets plugin, never in the plugin's own files, because updates overwrite them.
// Run your own code when YaExam fires an action
add_action( 'yaexam_after_exam_loop_item', function() {
// Your code runs here.
}, 10, 1 );
// Change a value YaExam is about to use
add_filter( 'yaexam_widget_settings_sanitize_option', function( $instance, $new_instance, $key, $setting ) {
// Change $instance here.
return $instance;
}, 10, 4 );Parts of a name in {braces} are filled in at runtime (for example a post type or field ID). Choose Example on any hook for a ready-to-edit snippet.
All hooks
-
/** * yaexam_after_exam_loop_item hook. */ do_action( 'yaexam_after_exam_loop_item' ); -
/** * yaexam_before_exam_loop_item hook. */ do_action( 'yaexam_before_exam_loop_item' ); -
/** * yaexam_exam_loop_item_summary hook. */ do_action( 'yaexam_exam_loop_item_summary' ); -
/** * quizmaker_single_test_result_summary hook. */ do_action( 'yaexam_single_exam_result_summary' ); -
/** * Sanitize the value of a setting. */ apply_filters( 'yaexam_widget_settings_sanitize_option', $instance[ $key ], $new_instance, $key, $setting ); -
do_action( 'yaexam_after_my_account' ); -
do_action( 'yaexam_before_my_account' ); -
apply_filters( 'yaexam_cached_widget_id', $this->widget_id ); -
apply_filters( "yaexam_get_settings_{$this->id}", $settings ); -
apply_filters( "{$this->identifier}_cron_interval", 5 ); -
do_action( 'yaexam_after_main_content' ); -
do_action( 'yaexam_before_main_content' ); -
apply_filters( 'yaexam_catalog_orderby', array( 'menu_order' => __( 'Default sorting', 'yaexam' ), 'date' => __( 'Sort by newness', 'yaexam' ), 'duration-asc' => __( 'Sort by duration: low to high', 'yaexam' ), 'duration-desc' => __( 'Sort by duration: high to low', 'yaexam' ), ) ); -
apply_filters( 'yaexam_default_catalog_orderby', get_option( 'yaexam_default_exam_orderby' ) ); -
apply_filters( 'yaexam_get_username_from_email', true ); -
do_action( 'yaexam_left_sidebar' ); -
apply_filters( 'yaexam_login_credentials', [ 'user_login' => $user->user_login, 'user_password' => $user->user_pass, 'remember' => true ] ); -
do_action( 'yaexam_login_form_end' ); -
do_action( 'yaexam_login_form_start' ); -
apply_filters( 'yaexam_login_shortcode_tag', 'yaexam_login' ); -
apply_filters( 'yaexam_my_account_shortcode_tag', 'yaexam_my_account' ); -
apply_filters( 'yaexam_register_shortcode_tag', 'yaexam_register' ); -
do_action( 'yaexam_right_sidebar' ); -
apply_filters( 'yaexam_session_expiring', 60 * 60 * 47 ); -
apply_filters( 'yaexam_session_use_secure_cookie', false ); -
apply_filters( 'yaexam_template_my_account_user_info_score', yaexam_get_user_score($user_id) ); -
apply_filters( "{$shortcode}_shortcode_tag", $shortcode ); -
apply_filters( "{$this->identifier}_default_time_limit", 20 ); -
apply_filters( "{$this->identifier}_memory_exceeded", $return ); -
apply_filters( "{$this->identifier}_queue_lock_time", $lock_duration ); -
apply_filters( "{$this->identifier}_time_exceeded", $return ); -
do_action_ref_array( "{current_filter()}_notification", $args ); -
do_action( 'after_yaexam_template_loop_exam_title' ); -
apply_filters( 'allow_password_reset', true, $user_data->ID ); -
do_action( 'before_yaexam_init' ); -
apply_filters( 'exam_get_default_settings', [ 'attempt' => 0, 'duration' => 0, 'publish_for' => 2, 'show_result' => 'yes', 'show_ranking' => 'yes', 'shuffle_questions' => 'yes', 'shuffle_answers' => 'yes', 'save_later' => 'no', 'email_user_result' => 'yes' ], $post_id ); -
do_action( 'exammaker_after_single_exam_ranking' ); -
do_action( 'exammaker_before_single_exam_ranking' ); -
apply_filters( 'get_exam_search_form', ob_get_clean() ); -
apply_filters( 'https_local_ssl_verify', false ); -
apply_filters( 'is_yaexam', ( is_exam_taxonomy() || is_exam() ) ? true : false ); -
apply_filters( 'login_errors', $e->getMessage() ); -
apply_filters( 'loop_exam_per_page', get_option( 'yaexam_posts_per_page' ) ); -
do_action( 'lostpassword_post' ); -
do_action( 'password_reset', $user, $new_pass ); -
apply_filters( 'plugin_locale', get_locale(), 'yaexam' ); -
do_action( 'pre_get_exam_search_form' ); -
do_action( 'retrieve_password', $user_login ); -
do_action( 'retrieve_password_key', $user_login, $key ); -
do_action( 'validate_password_reset', $errors, $user ); -
apply_filters( 'widget_title', empty( $instance['title'] ) ? '' : $instance['title'], $instance, $this->id_base ); -
apply_filters( "yaexam_add_{$message_type}", $message ); -
do_action( 'yaexam_add_addon' ); -
do_action( 'yaexam_admin_before_update_question', $post ); -
apply_filters( 'yaexam_admin_exam_display_setting', [ ['id' => 'show_result', 'name' => 'show_result', 'label' => esc_html__('Show Result', 'yaexam'), 'value' => $show_result], ['id' => 'show_ranking', 'name' => 'show_ranking', 'label' => esc_html__('Show Ranking', 'yaexam'), 'value' => $show_ranking], ['id' => 'shuffle_questions', 'name' => 'shuffle_questions', 'label' => esc_html__('Shuffle Questions', 'yaexam'), 'value' => $shuffle_questions]... ); -
apply_filters( 'yaexam_admin_exam_general_setting', [ [ 'id' => 'publish_for', 'name' => 'publish_for', 'type' => 'radiobox', 'label' => esc_html__('Publish for', 'yaexam'), 'options' => apply_filters('yaexam_publish_for',[ ['label' => esc_html__('Login Users', 'yaexam'), 'value' => 2], ]), 'value' => $publish_for ], ['id' => 'duration', 'name' => 'duration', 'label' => esc_html__('Duration', 'yaexam'), 'type' => 'number', 'attrs' => 'min="0"', ... ); -
do_action( "yaexam_admin_field_{$value['type']}", $value ); -
apply_filters( 'yaexam_admin_get_memberships_query', $args ); -
do_action( 'yaexam_admin_question_content' ); -
apply_filters( 'yaexam_admin_render_exam_result_column', admin_url("edit.php?exam={$post->ID}&action=filter&post_type=exam&page=em-results"), $post->ID ); -
apply_filters( 'yaexam_admin_save_exam_setting', array( 'attempt' => $attempt, 'duration' => $duration, 'publish_for' => $publish_for, 'show_result' => $show_result, 'show_ranking' => $show_ranking, 'shuffle_questions' => $shuffle_questions, 'shuffle_answers' => $shuffle_answers, 'save_later' => $save_later, 'email_user_result' => $email_user_result, 'exam_type' => 'normal', ) ); -
apply_filters( 'yaexam_admin_settings_sanitize_option', $value, $option, $raw_value ); -
apply_filters( "yaexam_admin_settings_sanitize_option_{$option_name}", $value, $option, $raw_value ); -
do_action( 'yaexam_after_exam_loop' ); -
do_action( 'yaexam_after_my_account_view_result' ); -
do_action( 'yaexam_after_not_start_exam_template', $exam_id ); -
do_action( 'yaexam_after_register', $user_id ); -
do_action( 'yaexam_after_register_taxonomy' ); -
do_action( 'yaexam_after_single_exam' ); -
do_action( 'yaexam_after_single_exam_result' ); -
do_action( 'yaexam_after_start_exam_template', $exam_id ); -
do_action( 'yaexam_after_submit_result', $result ); -
do_action( 'yaexam_after_template_part', $template_name, $template_path, $located, $args ); -
apply_filters( 'yaexam_after_widget_exam_list', '</ul></div>' ); -
do_action( "yaexam_ajax_{sanitize_text_field($action)}" ); -
do_action( 'yaexam_before_exam_loop' ); -
apply_filters( 'yaexam_before_get_user_exams', yaexam_get_user_meta( $user_id, 'exams' ) ); -
do_action( 'yaexam_before_my_account_view_result' ); -
do_action_ref_array( 'yaexam_before_register', array( $userData, &$user, &$errors ) ); -
do_action( 'yaexam_before_result_content', $result ); -
do_action( 'yaexam_before_result_sidebar', $result_id ); -
do_action( 'yaexam_before_single_exam' ); -
do_action( 'yaexam_before_single_exam_result' ); -
do_action( 'yaexam_before_start_exam', $exam_id ); -
do_action( 'yaexam_before_submit_result', $sid ); -
do_action( 'yaexam_before_template_part', $template_name, $template_path, $located, $args ); -
apply_filters( 'yaexam_before_widget_exam_list', '<div class="content"><ul class="em-ml-0 list-unstyled exam_list_widget">' ); -
apply_filters( 'yaexam_can_do_exam', $can_play, $exam_id ); -
apply_filters( 'yaexam_container_class', $classes, $class ); -
apply_filters( 'yaexam_create_page_id', $valid_page_found, $slug, $page_content ); -
apply_filters( 'yaexam_create_pages', array( 'archive_exam' => array( 'name' => _x( 'exams', 'Page slug', 'yaexam' ), 'title' => _x( 'Exams', 'Page title', 'yaexam' ), 'content' => '' ), 'myaccount' => array( 'name' => _x( 'yaexam-account', 'Page slug', 'yaexam' ), 'title' => _x( 'My Account', 'Page title', 'yaexam' ), 'content' => '[' . apply_filters( 'yaexam_my_account_shortcode_tag', 'yaexam_my_account' ) . ']' ), 'register' => ... ); -
apply_filters( 'yaexam_date_format', get_option( 'date_format' ) ); -
apply_filters( 'yaexam_default_exam_orderby', get_option( 'yaexam_default_exam_orderby' ) ); -
apply_filters( 'yaexam_disable_admin_bar', get_option( 'yaexam_lock_down_admin', 'yes' ) === 'yes' ); -
apply_filters( 'yaexam_doing_after_form', [], $post->ID ); -
do_action( 'yaexam_doing_header' ); -
do_action( 'yaexam_doing_sidebar_header' ); -
apply_filters( 'yaexam_doing_submit_redirect', yaexam_get_endpoint_url('em-result', $result_id, get_permalink( $exam_id )), $result ); -
do_action( 'yaexam_edit_account_form_end' ); -
do_action( 'yaexam_edit_account_form_start' ); -
do_action( 'yaexam_email', $this ); -
apply_filters( 'yaexam_email_actions', array( 'yaexam_email_new_member', 'yaexam_email_new_result', 'yaexam_email_reset_password' ) ); -
do_action( 'yaexam_email_header', $email_heading ); -
do_action( 'yaexam_email_new_member', $user_id ); -
do_action( 'yaexam_email_new_result', $result ); -
do_action( 'yaexam_email_reset_password', $user_login, $key ); -
apply_filters( 'yaexam_email_settings', array( array( 'title' => __( 'New Result', 'yaexam' ), 'type' => 'title', 'desc' => '', 'id' => 'email_new_result' ), array( 'title' => __( 'Subject', 'yaexam' ), 'id' => 'yaexam_email_setting_new_result_subject', 'type' => 'text', 'default' => 'Result: [{exam_title}]', 'class' => 'em-full-width', 'desc_tip' => true, ), array( 'title' => __( 'Header', 'yaexam' ), 'id' => 'yaexam_email_setting_n... ); -
apply_filters( 'yaexam_exam_categories_widget_args', $list_args ); -
do_action( 'yaexam_exam_doing' ); -
apply_filters( 'yaexam_exam_get_result_loop_score_data', $q->score, $q, $uq ); -
do_action( 'yaexam_exam_query', $q, $this ); -
do_action( 'yaexam_exam_result_info', $result ); -
apply_filters( 'yaexam_exam_title', $title, $this ); -
apply_filters( 'yaexam_exam_types', [ ['name' => 'normal', 'label' => 'Normal Exam'], ] ); -
apply_filters( 'yaexam_exams_widget_query_args', $query_args ); -
apply_filters( 'yaexam_filters_format_results', $result ); -
apply_filters( 'yaexam_general_settings', array( array( 'title' => __( 'General Options', 'yaexam' ), 'type' => 'title', 'desc' => '', 'id' => 'general_options' ), array( 'title' => __( 'Archive Page', 'yaexam' ), 'desc' => __( 'Page contents:', 'yaexam' ), 'id' => 'yaexam_archive_exam_page_id', 'type' => 'single_select_page', 'default' => '', 'class' => 'em-enhanced-select', 'css' => 'min-width:300px;', 'desc_tip' => true, ), array( '... ); -
apply_filters( "yaexam_get_{$page}_page_id", get_option('yaexam_' . $page . '_page_id' ) ); -
apply_filters( "yaexam_get_{$page}_page_permalink", $permalink ); -
apply_filters( 'yaexam_get_catalog_ordering_args', $args ); -
apply_filters( 'yaexam_get_endpoint_url', $url, $endpoint, $value, $permalink ); -
apply_filters( 'yaexam_get_exam_questions', $questions, $exam_id ); -
apply_filters( 'yaexam_get_exam_ranking', $results, $exam_id ); -
apply_filters( "yaexam_get_sections_{$this->id}", array() ); -
apply_filters( 'yaexam_get_settings_pages', $settings ); -
apply_filters( 'yaexam_get_template', $located, $template_name, $args, $template_path, $default_path ); -
apply_filters( 'yaexam_get_template_part', $template, $slug, $name ); -
do_action( "yaexam_hide_{$hide_notice}_notice" ); -
do_action( 'yaexam_init' ); -
do_action( 'yaexam_installed' ); -
do_action( 'yaexam_loaded' ); -
apply_filters( 'yaexam_locate_template', $template, $template_name, $template_path ); -
do_action( 'yaexam_log_add', $handle, $message ); -
do_action( 'yaexam_log_clear', $handle ); -
do_action( 'yaexam_login_form' ); -
apply_filters( 'yaexam_login_redirect', $redirect, $user ); -
apply_filters( 'yaexam_logout_redirect', site_url() ); -
do_action( 'yaexam_lostpassword_form' ); -
apply_filters( 'yaexam_message_types', array( 'error', 'success', 'notice' ) ); -
do_action( 'yaexam_my_account_after_sidebar', $args ); -
do_action( 'yaexam_my_account_before_sidebar', $args ); -
apply_filters( 'yaexam_my_account_my_exams_query', array( 'numberposts' => -1, 'post_type' => 'exam', 'include' => $exam_ids ) ); -
apply_filters( 'yaexam_my_account_tabs_content', true, $wp->query_vars ); -
apply_filters( 'yaexam_my_account_tabs_title', $args ); -
apply_filters( 'yaexam_page_title', $page_title ); -
apply_filters( 'yaexam_pagination_args', array( 'base' => esc_url_raw( str_replace( 999999999, '%#%', get_pagenum_link( 999999999, false ) ) ), 'format' => '', 'add_args' => false, 'current' => max( 1, get_query_var( 'paged' ) ), 'total' => $wp_query->max_num_pages, 'prev_text' => '←', 'next_text' => '→', 'type' => 'list', 'end_size' => 3, 'mid_size' => 3 ) ); -
do_action( "yaexam_process_{$post->post_type}_meta", $post_id, $post ); -
apply_filters( 'yaexam_process_login_errors', $validation_error, $username, $_POST['password'] ); -
apply_filters( 'yaexam_publish_for', [ ['label' => esc_html__('Login Users', 'yaexam'), 'value' => 2], ] ); -
apply_filters( 'yaexam_question_answer_types', array( 'single' => __( 'Single choice', 'yaexam' ), 'multiple' => __( 'Multiple choices', 'yaexam' ), 'fill_blank' => __( 'Fill in the blank', 'yaexam' ), 'drag_match' => __( 'Item match', 'yaexam' ), 'group_match' => __( 'Group match', 'yaexam' ), 'order' => __( 'Order', 'yaexam'), 'guess_word' => __( 'Guess Word', 'yaexam'), 'keywords' => __( 'Keywords', 'yaexam'), ) ); -
apply_filters( 'yaexam_question_is_correct', $is_correct, [$question_1, $value] ); -
apply_filters( 'yaexam_question_types', [ 'single' => __( 'Single choice', 'yaexam' ), 'multiple' => __( 'Multiple choices', 'yaexam' ), ] ); -
do_action( 'yaexam_register_form' ); -
do_action( 'yaexam_register_form_end' ); -
do_action( 'yaexam_register_form_start' ); -
do_action( 'yaexam_register_post_type' ); -
apply_filters( 'yaexam_register_post_type_exam', array( 'labels' => array( 'name' => __( 'Exams', 'yaexam' ), 'singular_name' => __( 'Exam', 'yaexam' ), 'menu_name' => _x( 'Exams', 'Admin menu name', 'yaexam' ), 'add_new' => __( 'Add Exam', 'yaexam' ), 'add_new_item' => __( 'Add New Exam', 'yaexam' ), 'edit' => __( 'Edit', 'yaexam' ), 'edit_item' => __( 'Edit Exam', 'yaexam' ), 'new_item' => __( 'New Exam', 'yaexam' ), 'view' => __( 'View Exa... ); -
do_action( 'yaexam_register_taxonomy' ); -
do_action( 'yaexam_reset_password', $user ); -
do_action( 'yaexam_reset_password_form' ); -
do_action( 'yaexam_save_account_details', $user->ID ); -
do_action_ref_array( 'yaexam_save_account_details_errors', array( &$errors, &$user ) ); -
apply_filters( 'yaexam_save_account_details_required_fields', array( 'account_first_name' => __( 'First Name', 'yaexam' ), 'account_last_name' => __( 'Last Name', 'yaexam' ), 'account_email' => __( 'Email address', 'yaexam' ), ) ); -
do_action_ref_array( 'yaexam_save_register_errors', array( &$errors, &$user ) ); -
do_action( "yaexam_sections_{$current_tab}" ); -
apply_filters( 'yaexam_session_expiration', 60 * 60 * 48 ); -
apply_filters( 'yaexam_session_handler', YAEXAM_Session_Handler::class ); -
do_action( "yaexam_settings_{$current_tab}" ); -
do_action( "yaexam_settings_{sanitize_title($value['id'])}" ); -
do_action( "yaexam_settings_{sanitize_title($value['id'])}_after" ); -
do_action( "yaexam_settings_{sanitize_title($value['id'])}_end" ); -
apply_filters( "yaexam_settings_form_method_tab_{$current_tab}", 'post' ); -
do_action( "yaexam_settings_save_{$current_tab}" ); -
do_action( 'yaexam_settings_saved' ); -
do_action( 'yaexam_settings_start' ); -
do_action( 'yaexam_settings_tabs' ); -
do_action( "yaexam_settings_tabs_{$current_tab}" ); -
apply_filters( 'yaexam_settings_tabs_array', array() ); -
apply_filters( 'yaexam_show_admin_notice', true, $notice ); -
apply_filters( "yaexam_show_hide_class_{$type['name']}_{$name}", [$default] ); -
apply_filters( 'yaexam_single_exam_data_info', array( array( 'type' => 'text', 'label' => __('Duration', 'yaexam'), 'value' => $exam->get_duration() ), array( 'type' => 'text', 'label' => __('Attempt', 'yaexam'), 'value' => $exam->get_attempt() ), array( 'type' => 'text', 'label' => __('Questions', 'yaexam'), 'value' => count($exam->get_questions())), ), $exam->id ); -
apply_filters( 'yaexam_single_exam_start_exam_info', $exam_info, $exam_id ); -
do_action( 'yaexam_single_exam_summary' ); -
apply_filters( 'yaexam_start_doing_redirect', $redirect_url ); -
apply_filters( 'yaexam_taxonomy_args_exam_cat', array( 'hierarchical' => true, 'label' => __( 'Exam Categories', 'yaexam' ), 'labels' => array( 'name' => __( 'Exam Categories', 'yaexam' ), 'singular_name' => __( 'Exam Category', 'yaexam' ), 'menu_name' => _x( 'Categories', 'Admin menu name', 'yaexam' ), 'search_items' => __( 'Search Exam Categories', 'yaexam' ), 'all_items' => __( 'All Exam Categories', 'yaexam' ), 'parent_item' => __( 'Pare... ); -
apply_filters( 'yaexam_taxonomy_args_exam_tag', array( 'hierarchical' => false, 'update_count_callback' => '_wc_term_recount', 'label' => __( 'Exam Tags', 'yaexam' ), 'labels' => array( 'name' => __( 'Exam Tags', 'yaexam' ), 'singular_name' => __( 'Exam Tag', 'yaexam' ), 'menu_name' => _x( 'Tags', 'Admin menu name', 'yaexam' ), 'search_items' => __( 'Search Exam Tags', 'yaexam' ), 'all_items' => __( 'All Exam Tags', 'yaexam' ), 'edit_item' =... ); -
apply_filters( 'yaexam_taxonomy_args_exam_type', array( 'hierarchical' => false, 'show_ui' => false, 'show_in_nav_menus' => false, 'query_var' => is_admin(), 'rewrite' => false, 'public' => false, ) ); -
apply_filters( 'yaexam_taxonomy_objects_exam_cat', array( 'exam' ) ); -
apply_filters( 'yaexam_taxonomy_objects_exam_tag', array( 'exam' ) ); -
apply_filters( 'yaexam_taxonomy_objects_exam_type', array( 'exam' ) ); -
apply_filters( 'yaexam_template_my_account_link_tabs', array( 'view_results_link' => yaexam_get_endpoint_url( 'view-results', '', yaexam_get_page_permalink( 'myaccount' ) ), 'view_save_laters_link' => yaexam_get_endpoint_url( 'view-save-laters', '', yaexam_get_page_permalink( 'myaccount' ) ), 'view_edit_account_link' => yaexam_get_endpoint_url( 'view-edit-account', '', yaexam_get_page_permalink( 'myaccount' ) ), ) ); -
apply_filters( 'yaexam_template_my_account_tabs', array( 'view-edit-account', 'view-save-laters', 'view-results' => array('view-result'), 'view-certificates' => array('view-certificate'), ) ); -
apply_filters( 'yaexam_template_path', 'yaexam/' ); -
do_action( 'yaexam_update_options' ); -
do_action( "yaexam_update_options_{$current_tab}" ); -
do_action( "yaexam_update_options_{$this->id}_{$current_section}" ); -
do_action( 'yaexam_updated' ); -
apply_filters( 'yaexam_user_roles_can_view_result', 'administrator', $user->roles ); -
apply_filters( 'yaexam_view_results_of_user', get_current_user_id() ); -
do_action( "yaexam_widget_field_{$setting['type']}", $key, $value, $setting, $instance );
Generated from YaExam's GPL-licensed source code. Hooks inside bundled third-party libraries are not listed.
Done for you
Rather have it built for you?
Tell us what should change and we’ll write and test the code using these hooks.
Custom hook snippet
from $49
A small, update-safe change built on the plugin’s own hooks.
- Code written against the plugin’s actions and filters
- Tested on a staging copy of your site
- Install instructions included
Typical turnaround: 2–3 business days
Choose thisPlugin customisation
from $149
New features or changed behaviour, without editing the plugin’s files.
- Built as a companion plugin, so updates never wipe it
- Exact quote before we start
- Tested on staging, then deployed
Typical turnaround: 3–7 business days
Choose thisNot sure which fits? Describe what you need and we’ll suggest the simplest option.
Can't find the right hook?
We can build the customisation for you. Describe what you need: