PHP Class WPDiscourse\Validator\SettingsValidator

The methods are invoked by the call to apply_filters( $filter, $input ); in DiscourseAdmin#discourse_validate_options
Mostrar archivo Open project: discourse/wp-discourse

Protected Properties

Property Type Description
$sso_enabled
$use_discourse_comments

Public Methods

Method Description
__construct ( )
validate_allowed_post_types ( $input )
validate_api_key ( $input )
validate_auto_publish ( $input )
validate_auto_track ( $input )
validate_bypass_trust_level_score ( $input )
validate_comment_html ( $input )
validate_custom_datetime_format ( $input ) Tricky to validate. We could show the user an example of what their format translates into.
validate_custom_excerpt_length ( $input )
validate_debug_mode ( $input )
validate_enable_sso ( $input ) This is only called if the checkbox is 'checked'.
validate_existing_comments_heading ( $input )
validate_full_post_content ( $input )
validate_login_path ( $input )
validate_max_comments ( $input )
validate_min_replies ( $input )
validate_min_score ( $input )
validate_min_trust_level ( $input )
validate_no_replies_html ( $input )
validate_only_show_moderator_liked ( $input )
validate_participant_html ( $input )
validate_publish_category ( $input )
validate_publish_category_update ( $input )
validate_publish_format ( $input )
validate_publish_username ( $input )
validate_replies_html ( $input )
validate_show_existing_comments ( $input )
validate_sso_secret ( $input )
validate_url ( $input )
validate_use_discourse_comments ( $input ) This is only called if the checkbox is 'checked'.

Protected Methods

Method Description
sanitize_checkbox ( $input )
sanitize_html ( $input )
sanitize_text ( $input ) Helper methods
validate_int ( $input, $option_id, $min = null, $max = null, $error_message = '', $add_error = 1 )

Method Details

__construct() public method

public __construct ( )

sanitize_checkbox() protected method

protected sanitize_checkbox ( $input )

sanitize_html() protected method

protected sanitize_html ( $input )

sanitize_text() protected method

Helper methods
protected sanitize_text ( $input )

validate_allowed_post_types() public method

public validate_allowed_post_types ( $input )

validate_api_key() public method

public validate_api_key ( $input )

validate_auto_publish() public method

public validate_auto_publish ( $input )

validate_auto_track() public method

public validate_auto_track ( $input )

validate_bypass_trust_level_score() public method

validate_comment_html() public method

public validate_comment_html ( $input )

validate_custom_datetime_format() public method

Tricky to validate. We could show the user an example of what their format translates into.

validate_custom_excerpt_length() public method

public validate_custom_excerpt_length ( $input )

validate_debug_mode() public method

public validate_debug_mode ( $input )

validate_enable_sso() public method

This is only called if the checkbox is 'checked'.
public validate_enable_sso ( $input )

validate_existing_comments_heading() public method

validate_full_post_content() public method

public validate_full_post_content ( $input )

validate_int() protected method

protected validate_int ( $input, $option_id, $min = null, $max = null, $error_message = '', $add_error = 1 )

validate_login_path() public method

public validate_login_path ( $input )

validate_max_comments() public method

public validate_max_comments ( $input )

validate_min_replies() public method

public validate_min_replies ( $input )

validate_min_score() public method

public validate_min_score ( $input )

validate_min_trust_level() public method

public validate_min_trust_level ( $input )

validate_no_replies_html() public method

public validate_no_replies_html ( $input )

validate_only_show_moderator_liked() public method

validate_participant_html() public method

public validate_participant_html ( $input )

validate_publish_category() public method

public validate_publish_category ( $input )

validate_publish_category_update() public method

validate_publish_format() public method

public validate_publish_format ( $input )

validate_publish_username() public method

public validate_publish_username ( $input )

validate_replies_html() public method

public validate_replies_html ( $input )

validate_show_existing_comments() public method

validate_sso_secret() public method

public validate_sso_secret ( $input )

validate_url() public method

public validate_url ( $input )

validate_use_discourse_comments() public method

This is only called if the checkbox is 'checked'.

Property Details

$sso_enabled protected_oe property

protected $sso_enabled

$use_discourse_comments protected_oe property

protected $use_discourse_comments