WP_Customize_Setting::is_current_blog_previewed()
Return true if the current site is not the same as the previewed site.
Метод класса: WP_Customize_Setting{}
Хуков нет.
Возвращает
true|false
. If preview() has been called.
Использование
$WP_Customize_Setting = new WP_Customize_Setting(); $WP_Customize_Setting->is_current_blog_previewed();
Список изменений
С версии 4.2.0 | Введена. |
Код WP_Customize_Setting::is_current_blog_previewed() WP Customize Setting::is current blog previewed WP 6.6.2
public function is_current_blog_previewed() { if ( ! isset( $this->_previewed_blog_id ) ) { return false; } return ( get_current_blog_id() === $this->_previewed_blog_id ); }