Reorder the menu buttons


Home Forums Front End PM PRO Reorder the menu buttons

This topic is: Resolved
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #7454
    Dominique Baril
    Participant

    Hi Shamim,

    I’m trying to reorder the menu buttons by specifying a priority value. I tried both the following codes but it doesn’t work. Is there a way I could achieve such modification?

    Thanks

        $menu['newmessage']['priority'] = 1;
        $menu['messagebox']['priority'] = 2;
        $menu['announcements']['priority'] = 3;
        $menu['directory']['priority'] = 4;
        $menu['settings']['priority'] = 5;
        $menu['messagebox']  = array(
          'priority'    => 1,
        );
        $menu['announcements']  = array(
          'priority'    => 2,
        );
        $menu['settings']  = array(
          'priority'    => 3,
        );
    #7460
    Shamim Hasan
    Keymaster

    Please use a higher priority to your filter eg. add_filter( ‘fep_menu_buttons’, ‘your_function’, 50 );

    #7483
    Dominique Baril
    Participant

    Alright, thank you for time Shamim. I know you must be busy preparing this week release.
    Here’s the full function I try to make work. As you can see I use a priority of 99 for my filter and I unset the new message button.

    add_filter( 'fep_menu_buttons', 'fep_cus_fep_menu_buttons', 99 );
    function fep_cus_fep_menu_buttons( $menu )
    {
        unset( $menu['newmessage'] );
        $menu['messagebox']['priority'] = 1;
        $menu['announcements']['priority'] = 2;
        $menu['directory']['priority'] = 3;
        $menu['settings']['priority'] = 4;
        return $menu;
    }
Viewing 3 posts - 1 through 3 (of 3 total)

You need to purchase ‘Front End PM PRO’ to create topic in this support forum.

If you already purchased ‘Front End PM PRO’ please LOGIN.