admin bar custom icon in preview mode
-
I know WP quite well and have been creating child themes with innovative solutions for several years. There are only two points that, despite repeated testing, I still haven’t figured out.
I use TS (Twentyseventeen) as a base, and I don’t intend to change it.
Admin bar icon:
I’ve created several custom functions in admin, which open with a dropdown marked by our svg icon. Everything works perfectly, except that in the previews (.wp-singular.logged-in) it doesn’t find the “status 404” icon.
I’ve enqueued the icon both with “admin_bar_menu()” in the same menu as our custom functions, and I’ve enqueued a CSS file that calls out the icon. I repeat: everything works, but not in the previews.
The strangest thing is that the icon also works in the previews only when it’s blog (main category), while it’s not found in page, nor in my custom-taxonomies and custom post_type.
The icon path is get_stylesheet_directory() . ‘/…, or get_stylesheet_directory_uri() . ‘/…, which works perfectly in any admin page.
The other question concerns the HTML title, but only in the admin section: I’ll ask that question in the next topic.
Thanks to anyone who replies.
Mauro
You must be logged in to reply to this topic.