• Resolved evalast

    (@evalast)


    Hi, im trying to add a button to the userslist nav. It does not work if the plugin is activated – my code uses default action hook and is ok. Here the code – do you know whats the problem?

    add_action('manage_users_extra_tablenav', 'users_overviewlist_extra_tablenav_', 10, 1);
        function users_overviewlist_extra_tablenav_($which) {
            if ($which === 'top') { ?>
                        <div class="alignleft actions custom">              
    
                            <a class="button-primary" href="/wp-admin/users.php?role=customer"><?php _e('List of Customers', 'v-framework'); ?> &rarr;</a>
    
                        </div>
                        <?php
            }
        }   
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Mark Kevin

    (@mkesteban08)

    Hi @evalast ,

    Mark here, from the Premmerce’s support team. Thanks for reaching out!

    I double-checked the plugin, and it seems that it is also hooked into the default action hook which could be the cause of the conflict when you’re trying to add additional function to it, while the Premmerce plugin is active.

    Please try to use the “bottom” position instead, for your customization, and see if that would work.

    Please let me know if you have other questions, and I’ll be glad to help.

    Thread Starter evalast

    (@evalast)

    Hi – tried again and saw that my function only works when im on the Customers view not at the ALL view – regardless if your plugin is active or not. Im not sure which causes this issue but atm i fixed my problem a bit different without the code snippet. Thx for your help, best

    • This reply was modified 1 year, 1 month ago by evalast.
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Cant add custom code if the plugin is active’ is closed to new replies.