Not able to show the add_menu_page icon

You have added the directory name where do you have stored the icon and this should be the 6th argument rather than 5th. add_menu_page( ‘pms_rohitashv’, ‘PMS’, ‘subscriber’, ‘pms_rohitashv-main’, ”, plugin_dir_url( __FILE__ ).’/images/icon.png’ );

Highlight active Admin Menu when added though add_menu_page

add_filter( ‘parent_file’, ‘parent_file_hover’ ); function parent_file_hover( $parent_file ) { global $pagenow; if ( $pagenow == ‘post.php’) $parent_file = “post.php?post={$_REQUEST[‘post’]}&action=edit”; elseif($pagenow == ‘post-new.php’) $parent_file = “post-new.php?post_type={$_REQUEST[‘post_type’]}”; return $parent_file; }

do_shortcode() within Admin Page

Instead of calling do_shortcode() just call the function associated with the shortcode. Example There is a shortcode named [example] and a function registered as shortcode handler: function example_shortcode( $atts = array(), $content=”” ) { extract( shortcode_atts( array ( ‘before’ => ”, ‘after’ => ”, ), $atts ) ); return $before . $content . $after; } … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)