PHP Класс Jetpack_IDC, jetpack

С версии: 4.4.0
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$current_screen WP_Screen The current screen, which is set if the current user is a non-admin and this is an admin page.
$is_safe_mode_confirmed boolean Has safe mode been confirmed?
$wpcom_home_url string The wpcom value of the home URL

Открытые методы

Метод Описание
admin_page_has_help_tabs ( ) : boolean Does the current admin page have help tabs?
clear_all_idc_options ( ) Clears all IDC specific options. This method is used on disconnect and reconnect.
display_admin_bar_button ( )
display_idc_notice ( ) First "step" of the IDC mitigation. Will provide some messaging and two options/buttons.
display_non_admin_idc_notice ( )
enqueue_admin_bar_css ( )
enqueue_idc_notice_files ( ) Enqueue scripts for the notice
get_confirm_safe_mode_action_explanation ( )
get_confirm_safe_mode_button_text ( )
get_first_step_fix_connection_action_explanation ( )
get_first_step_fix_connection_button_text ( )
get_first_step_header_explanation ( )
get_first_step_header_lead ( )
get_migrate_site_action_explanation ( )
get_migrate_site_button_text ( )
get_non_admin_contact_admin_text ( )
get_non_admin_notice_text ( )
get_second_step_header_lead ( )
get_start_fresh_action_explanation ( )
get_start_fresh_button_text ( )
get_unsure_prompt ( )
init ( )
maybe_clear_migrate_option ( $processed_items ) This method loops through the array of processed items from sync and checks if one of the items was the home_url or site_url callable. If so, then we delete the jetpack_migrate_for_idc option.
non_admins_current_screen_check ( $current_screen )
prepare_url_for_display ( $url )
render_error_notice ( ) Is a container for the error notices.
render_notice_first_step ( )
render_notice_header ( )
render_notice_second_step ( )
wordpress_init ( )

Приватные методы

Метод Описание
__construct ( )

Описание методов

admin_page_has_help_tabs() публичный Метод

Does the current admin page have help tabs?
public admin_page_has_help_tabs ( ) : boolean
Результат boolean

clear_all_idc_options() статический публичный Метод

Clears all IDC specific options. This method is used on disconnect and reconnect.
static public clear_all_idc_options ( )

display_admin_bar_button() публичный Метод

display_idc_notice() публичный Метод

"Confirm Staging" - Dismiss the notice and continue on with our lives in staging mode. "Fix Jetpack Connection" - Will disconnect the site and start the mitigation...
public display_idc_notice ( )

display_non_admin_idc_notice() публичный Метод

enqueue_admin_bar_css() публичный Метод

enqueue_idc_notice_files() публичный Метод

Enqueue scripts for the notice

get_confirm_safe_mode_action_explanation() публичный Метод

get_confirm_safe_mode_button_text() публичный Метод

get_first_step_fix_connection_action_explanation() публичный Метод

get_first_step_fix_connection_button_text() публичный Метод

get_first_step_header_explanation() публичный Метод

get_first_step_header_lead() публичный Метод

get_migrate_site_action_explanation() публичный Метод

get_migrate_site_button_text() публичный Метод

get_non_admin_contact_admin_text() публичный Метод

get_non_admin_notice_text() публичный Метод

get_second_step_header_lead() публичный Метод

get_start_fresh_action_explanation() публичный Метод

get_start_fresh_button_text() публичный Метод

get_unsure_prompt() публичный Метод

public get_unsure_prompt ( )

init() статический публичный Метод

static public init ( )

maybe_clear_migrate_option() публичный Метод

This method loops through the array of processed items from sync and checks if one of the items was the home_url or site_url callable. If so, then we delete the jetpack_migrate_for_idc option.
public maybe_clear_migrate_option ( $processed_items )
$processed_items array Array of processed items that were synced to WordPress.com

non_admins_current_screen_check() публичный Метод

public non_admins_current_screen_check ( $current_screen )

prepare_url_for_display() статический публичный Метод

static public prepare_url_for_display ( $url )

render_error_notice() публичный Метод

Will be shown/controlled by jQuery in idc-notice.js
public render_error_notice ( )

render_notice_first_step() публичный Метод

render_notice_header() публичный Метод

render_notice_second_step() публичный Метод

wordpress_init() публичный Метод

public wordpress_init ( )

Описание свойств

$current_screen статическое публичное свойство

The current screen, which is set if the current user is a non-admin and this is an admin page.
static public WP_Screen $current_screen
Результат WP_Screen

$is_safe_mode_confirmed статическое публичное свойство

Has safe mode been confirmed?
static public bool $is_safe_mode_confirmed
Результат boolean

$wpcom_home_url статическое публичное свойство

The wpcom value of the home URL
static public string $wpcom_home_url
Результат string