Reproduce:
------------------
1. Create a profile link field
2. Create a view that displays that field for a given user (based on an argument; or show for all users). Set the field to "Hide if empty" and "Display as a link".
3. Display the view set for a user that has not filled out that field. It still shows, regardless of these settings.

Comments

mstef’s picture

Version: 6.x-2.16 » 6.x-2.x-dev
Status: Active » Needs review
StatusFileSize
new567 bytes

The problem seems to be in views_handler_field_url.inc, which is what profile uses to output these fields. There are no checks for empty, or the hide if empty option.

Added a simple check in render(), excluding the check on "count zero as empty" because a URL cannot be 0:

if ($this->options['hide_empty'] && !$value) {
  return '';
}
mustanggb’s picture

Issue summary: View changes
Status: Needs review » Closed (won't fix)