Hot answers tagged

3

Lists like views will not be passed through hook_node_access(), as this would create too much overhead. Views does a query on the database to get the results. hook_node_access() is run in PHP, so these won't work (easily/well/efficently) together. To deal with lists, you will need to create a grant system, using hook_node_access_records() and ...


1

Run the check on page page load, not just on click: ... wrapped in the usual Drupal boilerplate disableFilter($('#edit-field-agegroup-value-1')); $('#edit-field-agegroup-value-1').click(function() { disableFilter($(this)); }); function disableFilter(element) { if( element.is(':checked')) { $("#edit-field-classroom-value-3").prop('...


1

Got it to work with the following code. I needed to output the changed value in the $vars['output']. This would override the url in the nothing_1 field so I then had to create a new link and use that to alter the original value. /** * Implements hook_preprocess_views_view_field(). */ function frontview_general_preprocess_views_view_field(&$vars) { $...


Only top voted, non community-wiki answers of a minimum length are eligible