WP_Customize_Setting::is_current_blog_previewed
Return true if the current site is not the same as the previewed site.
Method of the class: WP_Customize_Setting{}
No Hooks.
Returns
true|false. If preview() has been called.
Usage
$WP_Customize_Setting = new WP_Customize_Setting(); $WP_Customize_Setting->is_current_blog_previewed();
Changelog
| Since 4.2.0 | Introduced. |
WP_Customize_Setting::is_current_blog_previewed() WP Customize Setting::is current blog previewed code WP 7.0
public function is_current_blog_previewed() {
if ( ! isset( $this->_previewed_blog_id ) ) {
return false;
}
return ( get_current_blog_id() === $this->_previewed_blog_id );
}