How to allow only certain users access to certain fields of a node?
I have product information on my site. Only some users can view pricing for certain suppliers. So each product has a supplier field, which is a node entity reference to an instance of a "supplier" content type. When User A logs in, who only has access to Products Offered by Supplier B, he must only see the "cost price" of items that he is linked to...
Code for "All pages except those listed" in Show block on specific pages
While editing a block I want to use "Pages on which this PHP code returns TRUE (experts only)" at the same time support the URL's entered in "All pages except those listed" plus my own custom conditions. Where can I get the standard code to match those URL using PHP code? For example as in figure initially "All pages except those listed" is checked...
Show links only to sub menus items, not to parent menu
I added some links to Main menu and created sub links for it. Now the problem is that I've to give url to the parent menus of sub links. I want it to be disabled. Links should be for sub menus only. How can I do it. Please help. In the pic, I don't want link for 'Contact us
Show menu links for anonymous users only
I need to show the user register link as a menu item in the account menu. I am able to add the link in the menu via links.menu.yml. The menu links shows up for anonymous users as well as authenticated users but not for admin user role. How can I hide the menu item for logged in users irrespective of user role?