• Resolved pax1

    (@pax1)


    Hey,

    is there a way to hide frontend elements with php (i.e. menu items, sites….).
    With “remove_menu_page( $menu_slug );” I only get menus in the backend to dissappear.
    Pure CSS doesn’t work either because I need to filter different user roles and based on that, hide elements. Calling a JS from within php (via echo) is always failing because of the “headers are already be send” error.

    Thanks in andanve,
    Pascal

Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘PHP hide frontend items’ is closed to new replies.