I want to use a custom icon for custom post types. I see some old posts in the forum about it.
1. What is the current best way to do this? When you make a new post type and click choose icon, the choices are very limited.
- How can I make my own custom icons available in that list?
- Is there a way to offer all of font awesome 5 icons?
Thanks in advance.
Hello,
You are right, the correct way is: make a new post type and click choose icon
And you can customize the post type icon with custom codes, for example:
You can use WordPress built-in filter hook "register_post_type_args" to change the "menu_icon" parameter of your custom post types.
https://developer.wordpress.org/reference/hooks/register_post_type_args/
https://developer.wordpress.org/reference/functions/register_post_type/#menu_icon
It would be nice if we could just use a font awesome slug for it rather than having to go through all that. The options are very limited in what's offered.
Unfortunately, Toolset Types plugin is using WordPress built-in dash icons by default:
https://developer.wordpress.org/resource/dashicons/
If you need other icons, you will need to consider custom codes, see my answer above:
https://toolset.com/forums/topic/custom-icon-for-post-type-font-awesome/#post-2606229