0

I do not want to display the submissions button, the download button, and the customize button on the webform results tab for the user.

How can I do that?

enter image description here

0

The best way to hide menu item from the secondary tabs should be to alter the access callback of the menu item.

function mymodule_menu_alter(&$item) {
  // This hides the sbmissions item. Others should work simillary.
  $item['node/%webform_menu/webform-results/submissions']['access callback'] = 'mymodule_webform_result_access';
}

function mymodule_webform_result_access($node, $account = NULL) {
  // You can put here any custom logic of your needs.
  return FALSE; 
}
  • The question is for Drupal 8. – Kevin Feb 23 '17 at 14:20
0

To alter the tabs see https://www.drupal.org/docs/8/modules/webform/webform-cookbook/how-to-alter-local-tasks-aka-tabs

You might want to consider creating a custom view using the Webform Views module

-1

The simpler way is with css, display:none to the elements you want

  • This isn't secure. The permissions should be adjusted. – Kevin Feb 23 '17 at 12:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.