Questions tagged [admin-menu]

Usually, plugin and theme authors need to provide access to a settings (options) screen so users can customize how the plugin or theme is used. The best way to present the user with such a screen is to create an administration menu item that allows the user to access that settings screen from all the Administration Screens.

Filter by
Sorted by
Tagged with
0 votes
0 answers
22 views

Create a menu and a submenu

I'm trying to create a menu and a submenu in wordpress, here is the code: <?php require_once(ABSPATH.'wp-config.php'); require_once(ABSPATH.'wp-includes/pluggable.php'); require_once(ABSPATH.'wp-...
Bruno Lima's user avatar
0 votes
1 answer
26 views

Remove custom menu pages for admin users

I've added some custom menù pages to my WordPress dashboard using the add_menu_page() function. I need to remove these pages for super admin roles, but the remove_menu_page() seems not working. This ...
ICTDEV's user avatar
  • 113
0 votes
1 answer
52 views

Import bootstrap 5 and bootstrap icons in wp-admin backend

I want to fully customize the wp-admin interface. I'm creating some plugins to remove the default menu pages and to add my custom pages, and seems working fine.Anyway I need to implement bootstrap 5 ...
ICTDEV's user avatar
  • 113
0 votes
1 answer
74 views

Wordpress add menu items display slug too

Using the Wordpress menu system to add an item (product category in my case). I have categories with the same name, under a different parent category, so when i search for the category i want it may ...
John's user avatar
  • 101
0 votes
0 answers
26 views

My custom fonts are uploaded and included in the list but do not apply

I created a dashboard that provides the option to upload fonts in .woff format which will be used with the Kirki framework. The files are added successfully but I can't figure out where to output the @...
justtme's user avatar
0 votes
1 answer
115 views

Can't add custom post type archive page to menu

I cannot add this custom post type archive page to any menu from the admin. Adding via the front end customizer works fine. Viewing the archive page on the front end also works fine. My custom post ...
Tommizzy's user avatar
0 votes
2 answers
18 views

Adding admin link to Appearance via admin_menu, adds link to theme details modal

When you use admin_menu hook to add a navigation item to the Appearances section in the admin menu it will also add that link to the modal that pops up when you click "Theme Details", ...
Kender's user avatar
  • 133
0 votes
1 answer
20 views

Add items to the dark menu in WordPress

I would like to add a category (is that what it's called?) such as 'Articles' to the WordPress menu. Not the one that will be visible to the end user, but this menu: Ty
LuchiniChiara's user avatar
0 votes
0 answers
47 views

Add Woocommerce Customers link to custom admin menu

I'm creating a custom admin menu with my plugin and I want to add the Woocommerce Customers page as a submenu item. That was simple enough with add_submenu_page. Now I'm trying to set my custom top ...
FinnFIN's user avatar
0 votes
1 answer
564 views

Submitting form to admin-post.php Wordpress

I've been trying to get a basic plugin to work and I have followed what seems to be the flow to get the form to post to admin-post.php. However, I only seem to get the white screen of death upon form ...
Yintii.eth's user avatar
0 votes
0 answers
60 views

Remove menu pages only for non admin

I have this method in my plugin, I want to avoid that the users that are not administrator can see some menus in the dashboard. I know that this can be achived using the roles, but in my case I will ...
ICTDEV's user avatar
  • 113
1 vote
0 answers
98 views

admin_enqueue_scripts using hook_suffix vs GET page

My menu code: add_action('admin_menu', 'waf_admin_menu'); function waf_admin_menu(){ add_menu_page('WordPress Audio Filter', 'WordPress Audio Filter', WAF_CAPABILITY, 'waf_settings', '...
Toniq's user avatar
  • 437
1 vote
1 answer
51 views

Show Admin Menu

I am learning WordPress Plugin development. I need to create a Add New sub-menu like this image: My code is like below: public function register_custom_post_type() { $supports = ['title']; $...
Foysal's user avatar
  • 417
0 votes
0 answers
30 views

Display admin sidebar into custom post pages if logged

Is it possible to display the default admin sidebar in a custom post type page (frontend view) if user is logged in, as happens for the admin top bar? If is possible, how can I do this? Any hint?
vvave vvave's user avatar
1 vote
1 answer
34 views

Admin menu link with variable

I used this function to display a log out link below the home icon. But how could I put a variable, for instance the current username, on that link to show a profile page? The function is: ...
markseinto's user avatar
0 votes
1 answer
26 views

Admin submenu issue with PHP not detecting two strings as equal

I am adding a submenu page as follows: add_submenu_page( $slug, __('Categories','acs'), __('Categories','acs'), $cap, 'edit-tags.php?taxonomy=acs-field-group-category&post_type=acs-field-group' ); ...
Álvaro Franz's user avatar
1 vote
2 answers
83 views

How to add query args to links to CPT admin submenu

I have a custom post type I've created, and I've added an admin submenu page to display some data it generates. So far, so good. I'm displaying the data with my local extension of WP_List_Table, and I ...
philolegein's user avatar
0 votes
1 answer
216 views

How to make an admin plugin menu page go full screen?

I'm building a plugin that contains a simple editor for a particular file format. This will only be accessible in the admin menu's for the plugin, no frontend access. I've started looking at the ...
AutoBaker's user avatar
  • 151
0 votes
0 answers
49 views

Metaboxes inside Tab

I am learning WordPress Plugin development. In this regard I have to save some settings along with Custom Post in Admin Panel under a Menu. Can I place metaboxes inside tab for this issue like the ...
Foysal's user avatar
  • 417
0 votes
1 answer
360 views

Change the destination of the URLs in post.php

The post.php screen lists posts vertically in the admin area [and other post types]. Each item's post_title is a hyperlink, directly above some inline choices. Both the title link, and the "Edit&...
John Dee's user avatar
  • 503
0 votes
0 answers
70 views

How can I change the admin menu title and url title on WordPress

I was hoping someone can help me on how to change the admin menu title and also the link title that goes with it. I want to change Projects admin menu title to Services admin menu. Also, change the ...
Yor Ganawil's user avatar
0 votes
1 answer
162 views

Unable to get a simple plugin admin page to work

Even though I have years of software development experience, I am new to WP & PHP development, so please bear with me. After reading through the plugin manual, I started with a WP plugin boiler ...
helgew's user avatar
  • 111
0 votes
1 answer
32 views

Different Admin language

We are running our WP site in Hungarian but nobody in our team understands this language. We successfully changed admin backend language to our native language but not everything changed. We are still ...
Vlado's user avatar
  • 113
1 vote
0 answers
163 views

Calling the "wp-link-wrap" pop-up modal

When using the ACF, I noticed that the "Select Link" button calls a native modal called "wp-link-wrap". How can I call/access this modal without ACF?
G Chen Sin's user avatar
1 vote
1 answer
124 views

Visiting a console submenu page does not expand its parent menu item

*I have moved a custom post taxonomy to another menu item //created a post type that does not appear in admin menu, therefore its taxonomy does not, too $args = array( 'label' ...
Artem's user avatar
  • 305
1 vote
0 answers
335 views

Custom post types as sub menu pages and role capabilities issue

I'm working on this: Create a menu entry in the admin panel name "Products" Have a dozen of custom post types, all as submenus items of my admin menu "Products" entry Allow a role ...
Bardyl's user avatar
  • 111
0 votes
1 answer
27 views

Custom admin menu order fails if slugs are complicated

I'm not able to reorder WP Admin menu items when pages added with add_menu_page have complicated slugs. At least I think that's the problem... First I create the custom menu items, which is working as ...
EdA's user avatar
  • 103
0 votes
0 answers
482 views

Creating an admin button that when clicked shows a popup form

I am creating a custom plugin to add a button to the buttons panel when editing a post or page in the classic editor. I have no trouble adding a button to the panel, but am unsure of the best way to ...
Johnathan's user avatar
0 votes
1 answer
274 views

Give admin_menu permission to specific users

I created a admin menu for my Wordpress website. The capabillity / rules are set to manage_options. Now I want give permission to another user that is only an editor. Does anybody know how I can do ...
Jop's user avatar
  • 27
0 votes
1 answer
459 views

how to save checkbox data for custom setting?

I am creating one custom setting panel, my codes are function custom_text_field_html(){ $text = get_option( 'homepage_text' ); printf( '<input type="text" id="...
Ricky's user avatar
  • 53
0 votes
0 answers
34 views

Custom admin menu items

I'm very new to Wordpress, familiar with CMS though. I am taking over someone else's wordpress website, by comparing with other wordpress, I found this one has some admin menus that the other doesn't ...
shenkwen's user avatar
  • 131
1 vote
1 answer
855 views

Wordpress Side Menu Admin Panel Default Order numbers List?

Is there a page on the WP documentation someplace that lists the order numbers for the default menu items in the Admin panel on Wordpress? Cannot find anything on line that just gives a clear ...
Bradley's user avatar
  • 113
0 votes
1 answer
189 views

add sub_menu to a sub_menu (multiLevel sub_menu) in admin menu in wordpress

I'm looking to add a submenu, to another sub_menu that already exists. In WordPress, there are just 2 levels of admin menu (with functions: add_menu_page and add_submenu_page), my goal is to add ...
Leo's user avatar
  • 1
0 votes
1 answer
46 views

How to align the top of an admin pointer to the target element?

I am trying to create admin pointers for a plugin. First, I'm enqueuing the right assets: wp_enqueue_script( 'jquery' ); wp_enqueue_style( 'wp-pointer' ); wp_enqueue_script( '...
alexg's user avatar
  • 245
0 votes
1 answer
239 views

Restrict admin pages for specific user role

I have created new user role "advertiser" and added some capabilities: function prefix_add_user_role() { add_role( 'advertiser', 'Advertiser', array( '...
Juraj's user avatar
  • 144
0 votes
1 answer
572 views

How to break line / add <br> to ADMIN menu

Disclaimer: This question is not about "frontend" nav menu I am looking for a way how to break line in a menu item label in WP admin sidebar menu, sidereason is that the custom post type ...
jave.web's user avatar
  • 477
0 votes
0 answers
24 views

User role and capablities only for 1 plugin

What if i want a user called Marketing only to see the Slimstat plugin? The rest of the admin menu should be invisible for him. (for a external marketing agency that should see our stats but only our ...
MarcoDocker's user avatar
0 votes
0 answers
167 views

Block access to plugins.php for custom role

So I have a custom role and I'd like to block access to the plugins.php page without using a plugin. I can remove pages from the admin menu with my functions file but not sure how to restrict access
user1961395's user avatar
0 votes
1 answer
47 views

How to sort by two meta keys in admin area?

I am sorting a custom post on a page by a meta key called Order ordered by DESC followed by a meta key called Sub order ordered by ASC but I can't fathom how to do the same sorting in the WordPress ...
edwinbradford's user avatar
0 votes
0 answers
237 views

Hook event for upload image in the menu

I have to add the image in my dropdown. I know I can do this with CSS Classes (optional) but I don't want to do this. I want to add dynamically instead of open the code and change or add it. What I am ...
Naren Verma's user avatar
0 votes
1 answer
8 views

Cannot include custom post item within a menu

I'm trying to insert my custom post type within a menu of a theme. This theme actually have a custom post type called st_tours. So when I register my custom post type I do: $args = array( 'labels' ...
sfarzoso's user avatar
0 votes
1 answer
143 views

Why WP_Screeen doesn't show all options with admin_body_class

I was trying to add a specific class to the admin section. I created a new top-level menu page and now I want to add a specific class to this top-level menu and its submenu items. What I have tried so ...
Raashid Din's user avatar
0 votes
0 answers
433 views

Show all admin menus in a table

I Made a menu to remove admin menus for people that are not allowed to see it so they don't make changes to the site. But I can't get submenus to display only the main menu's this is the code: &...
Bent's user avatar
  • 1
0 votes
2 answers
300 views

Wordpress add page under admin submenu and retaining the active status of the parent submenu page in the menu

I have added a page in the admin menu(pxmag-menu) and a submenu(pxmag-plans). There is another page(pxmag-plans-edit) set under the submenu(pxmag-plans) as the parent page. public function __construct(...
sariDon's user avatar
  • 255
1 vote
1 answer
1k views

Add custom fields to specific menus

How do I add custom fields to a specific menu? For example, I have menu "Primary" with ID 13. How do I run the wp_nav_menu_item_custom_fields hook only if ID matches the currently selected ...
Justin Breen's user avatar
0 votes
0 answers
235 views

Wordpress Admin Panel Left Sidebar No showing on Post create page

These are two different WordPress sites on post create pages. The first site has left the admin panel. The second admin panel does not have a left sidebar. How can I add the left sidebar on the second ...
Chadsmith's user avatar
0 votes
1 answer
198 views

Weird white space in admin area

I have had this weird whitespace appear multiple times on multiple sites. By "appear" I mean, it wasn't there one day, then it was. I am the only admin on these sites, which are in the cloud....
John Dee's user avatar
  • 503
0 votes
1 answer
61 views

WP components no style

I'm trying to build a plugin menu using wordpress components but it appears all the styles are missing. For ex. the button isn't colored the primary(Blue) in the following sandbox.. https://...
Nav Saini's user avatar
1 vote
0 answers
113 views

Set different custom menu items for different user roles

I have added some custom menu using add-menu_page and it is working perfectly with the default administrator admin bar. But when I log in to different user roles, they are not showing. My question is ...
Avijit Palit's user avatar
0 votes
1 answer
2k views

on change form submit variable value not updating

I try to make custom theme option, a switch select option can change $bannerchange value. but i cannot add/update value of $bannerchange, select option inside a form. working fine with submit button ...
Noufal Binu's user avatar

1
2 3 4 5
13