Hello, I purchased ASM Pro in order to utilize the custom link text available in Screen Options, but it appears that doesn’t appear on custom post types. Is that an option or is there an adjustment I can easily make to achieve this?
Custom Link Text for Custom Post Types
Resolved
OnPoint Plugins
Hi Ralph,
I like the idea of having support for titles on custom post types which are available to use in the widgets. I have added this feature to a list of features for an upcoming release.
In the meantime you may add the following filter to your active theme’s functions.php file to enable this now.
Have a great night!
Mat Lipe
Ralph Miller
Thank you for the quick reply! I just added it, but it thows a 500 error or something that is preventing the site from loading with this in there. It says it’s getting hung up on that (?) question mark before get_post_types.
Thoughts?
OnPoint Plugins
Hi Ralph,
Looks like the code formatting was showing the incorrect character.
This has been fixed.
Have a great night!
Mat Lipe
Ralph Miller
Hi Mat,
I have this custom code you provided to implement custom link text on a custom post type. I recently upgraded to v8 and it’s causing trouble when editing post types.
I looked at your migration guide and attempted to update it to the code below, but I’m sure it needs to be done differently now. Can you please let me know what I’d need to change this code to in order for this to work?
Are there any updates on getting this feature added natively instead of using this custom code? Thank you!
add_action( ‘add_meta_boxes’, function() {
array_map( function ( $post_type ) {
add_meta_box( ‘asm-custom-title’, esc_html__( ‘Advanced Sidebar Menu’, ‘advanced-sidebar-menu’ ),
[ Advanced_Sidebar_Menu_Pro\Meta\Title::instance(), ‘metaBoxOutput’ ], $post_type, ‘side’, ‘high’ );
}, array_keys( \Advanced_Sidebar_Menu_Pro\Widget_Options\Page\Post_Type::instance()->get_post_types() ) );
} );
OnPoint Plugins
Hi Ralph,
Please give this a try:
This feature has not yet been added to an active sprint, but is currently #2 on our todo list for new features.
Have a great weekend!
OnPoint Plugins
Hi Ralph,
Version 8.1.0 is now available which includes support for changing the titles on, or excluding custom post types.
You may remove your filter once you update to 8.1.0.
Enjoy!