Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
To fix, add
function access() {
return TRUE;
}
to views\modules\contact\views_handler_field_contact_link.inc
If users do not have access to an individual's contact form then render() will return empty string because of permission check there. As is, column is entirely missing which causes problems when displaying in table format.
Comment | File | Size | Author |
---|---|---|---|
#6 | 734706-3.views_.contact-form-access.patch | 1.33 KB | joachim |
#4 | 734706-2.views_.contact-form-access.patch | 1.61 KB | joachim |
#2 | 734706.views_.contact-form-access.patch | 1.65 KB | joachim |
Comments
Comment #1
merlinofchaos CreditAttribution: merlinofchaos commentedThe existing behavior is the intended behavior. how is it a bug that users are prevented from viewing items they do not have access to view?
Comment #2
joachim CreditAttribution: joachim commentedNope, this is a bug -- just the OP meant to say "If users do not have access to an individual's *PROFILE*".
Users without 'access user profiles' are still given access to the contact form tab, but they are blocked from seeing the contact form link views field because views_handler_field_contact_link inherits access from its parent.
Patch on Views 2/3, tested on 2 but not 3.
Comment #3
dawehnerwhat about a return FALSE, this might make more sense.
Powered by Dreditor.
Comment #4
joachim CreditAttribution: joachim commentedGood point. Changed that and fixed that bit of whitespace.
Comment #5
dawehnerany reason for this?
This is not the mest if earl wants the patch, there might be conflicts at this line :)
Powered by Dreditor.
The rest is rtbc
Comment #6
joachim CreditAttribution: joachim commentedArg... ;)
Comment #7
dawehnerWorks fine and looks fine.
Comment #8
merlinofchaos CreditAttribution: merlinofchaos commentedCommitted.