ycliper

Популярное

Музыка Кино и Анимация Автомобили Животные Спорт Путешествия Игры Юмор

Интересные видео

2025 Сериалы Трейлеры Новости Как сделать Видеоуроки Diy своими руками

Топ запросов

смотреть а4 schoolboy runaway турецкий сериал смотреть мультфильмы эдисон
Скачать

How to Add Custom Link to Menu in Wordpress | How to Add Custom Links in Wordpress

add custom link in wordpress admin menu

wordpress add to admin bar

add menu in wordpress admin panel

wordpress add button to admin bar

how to add sub menu in wordpress admin dashboard

wordpress admin bar customize

customize wordpress admin bar

wordpress adminbar

customize wordpress adminbar

custom admin bar

wordpress

How to Add Custom Links in Wordpress Admin Menu

wordpress admin bar customization

Автор: WebStylePress

Загружено: 2023-03-13

Просмотров: 700

Описание: How to add custom links in wordpress admin menu? Inside WordPress admin panel, we have wordpress 'admin menu bar', also called as 'admin bar' or 'admin toolbar'. How can we add custom links or a dropdown menu in admin bar? Sometimes we need to access a page more often than other pages. I want to add custom links for pages in wordpress admin bar. Similarly you might want to add your own shortcuts to the pages you use most. Lets see process of wordpress admin bar customization and customize WordPress admin bar.

Go to plugins and search for 'WP Custom Admin Interface'. Install and activate the plugin. Under 'custom admin interface', click at 'admin toolbar' link. This page displays everything that appears on the toolbar and allows you to add new items. To add a custom shortcut link to the admin toolbar, click the 'Add Menu Item' button. Edit the 'menu title' and 'menu link' by clicking icons infront of input fields. Drag and drop menu link to desired place.

From below, infront of implement this for, select 'everyone'. You can add exception case for other users in case you want this link to be visible for only certain group of wordpress users such as, you can prevent subscriber, editor or other users from viewing this new link.

Save changes. Reload the page. Newly added link is added in admin bar. You can also add more links or create a dropdown menu. For example I want my custom links to be under 'My Menu'.

Click 'Add menu item'.
Type the name, place it above your links.
Re arrange custom link.
Save changes.
Now pevious link is below 'My Menu' in the adminbar.

Similarly you can add more links, create menus, submenus, edit links, hide links and control everything that is visible in admin bar.

If you make any mistake, you can always restore default toolbar by clicking this button that says 'restore to default wordpress toolbar'.

This plugin can do a lot more then this. You can explore those options, under its entry in sidebar.

If you don't want to use this plugin, we can add links in admin bar by using small piece of code as well. Go to theme file editor, edit functions.php file and add code in it.

Defined a function called custom_toolbar_link, which takes wp_admin_bar as a parameter that is the WordPress admin toolbar object. Then an array called args is created with key-value pairs:

id: The ID of the custom toolbar link.
title: The title of the custom toolbar link.
href: The URL of the custom toolbar link.
meta: An array of metadata for the custom toolbar link, including the class and title attributes.
The add_node() method is called on the wp_admin_bar object,
which adds a node to the WordPress admin toolbar. The $args array is passed as a parameter, which defines the custom link.

The add_action() function is used to hook the custom_toolbar_link function to the admin_bar_menu action. The third parameter 999 is the priority of the action, which determines when the function should be executed. In this case, it is set to 999, which means that the custom link will be added to the end of the toolbar menu.

So the links will be added in admin bar like that and you can also add more links under that link as shown in the video.

So this is how you can add single link or menu and sub menu in wordpress adminbar by using a plugin or custom code.

Our tutorials help you to improve your career growth, perform better in your job and make money online as a freelancer. Learn the skills to build and design professional websites, and create dynamic and interactive web applications using JavaScript, or WordPress. Our tutorials are tailored to help beginners and professionals alike. Whether you're just starting in the field or you're looking to expand your knowledge, we've got something for you. Join us on this journey to becoming a skilled web developer. Subscribe to our channel and let's get started!

Thank You!
👍 LIKE VIDEO
👊 SUBSCRIBE
🔔 PRESS BELL ICON
✍️ COMMENT

⚡Channel:    / @webstylepress  
⚡Website: https://www.webstylepress.com
⚡FaceBook:   / webstylepress  
⚡Twitter:   / webstylepress  
⚡GitHub: https://github.com/webstylepress
#WebStylePress #WordPress #WordPressTutorial #WordPressTraining #WordPressForBeginners #WordpressPlugin #WebDevelopment #WordpressDeveloper

Не удается загрузить Youtube-плеер. Проверьте блокировку Youtube в вашей сети.
Повторяем попытку...
How to Add Custom Link to Menu in Wordpress | How to Add Custom Links in Wordpress

Поделиться в:

Доступные форматы для скачивания:

Скачать видео

  • Информация по загрузке:

Скачать аудио

Похожие видео

© 2025 ycliper. Все права защищены.



  • Контакты
  • О нас
  • Политика конфиденциальности



Контакты для правообладателей: [email protected]