Posts

Showing posts with the label Admin

Wordpress - Add A Separator To The Admin Menu?

Answer : Here's a quick and dirty way to get what you want. Background WordPress stores admin menu sections in a global array called $menu . To add a separator you add an element to the $menu array using an index that is between the indexes of the options that you want to separate. Using the add_admin_menu_separator() function So I've written a function to encapsulate the logic for this I called add_admin_menu_separator() . You'll need to pick an array index number that is higher than the option after which you want to add a separator, and then call the function add_admin_menu_separator() passing said index as your parameter. For example: add_admin_menu_separator(37); The add_admin_menu_separator() function itself Here's the definition of the function add_admin_menu_separator() which you can copy into your theme's functions.php file. Yes it is arcane but then so is the code that creates and uses the global $menu array. (Plans are to eventu...

Admin Url Redirecting To Localhost/admin

Answer : First change from http://localhost/sitename to http://127.0.0.1/sitename/ second, after doing this remove var/cache folder. Check your  Baseurl  and  Baseurl secure    Change From :- localhost To :- 127.0.0.1 Then Run This Command :- sudo php bin/magento cache:flush sudo php bin/magento cache:clean