WPSEO_Metabox_Editor::add_css_inside_editor()
Adds our inside the editor CSS file to the list of CSS files to be loaded inside the editor.
Метод класса: WPSEO_Metabox_Editor{}
Хуков нет.
Возвращает
Строку
. The CSS files WordPress wants to load and our CSS file.
Использование
$WPSEO_Metabox_Editor = new WPSEO_Metabox_Editor(); $WPSEO_Metabox_Editor->add_css_inside_editor( $css_files );
- $css_files(строка) (обязательный)
- The CSS files that WordPress wants to load inside the editor.
Код WPSEO_Metabox_Editor::add_css_inside_editor() WPSEO Metabox Editor::add css inside editor Yoast 24.6
public function add_css_inside_editor( $css_files ) { $asset_manager = new WPSEO_Admin_Asset_Manager(); $styles = $asset_manager->special_styles(); $inside_editor = $styles['inside-editor']; $asset_location = new WPSEO_Admin_Asset_SEO_Location( WPSEO_FILE ); $url = $asset_location->get_url( $inside_editor, WPSEO_Admin_Asset::TYPE_CSS ); if ( $css_files === '' ) { $css_files = $url; } else { $css_files .= ',' . $url; } return $css_files; }