class record_shorten_views_handler_field_hostname in Shorten URLs 6
Same name and namespace in other branches
- 8 modules/record_shorten/record_shorten_views_handler_field_hostname.inc \record_shorten_views_handler_field_hostname
- 7.2 record_shorten_views_handler_field_hostname.inc \record_shorten_views_handler_field_hostname
- 7 record_shorten_views_handler_field_hostname.inc \record_shorten_views_handler_field_hostname
Restricts access to viewing the IP address field. There doesn't seem to be a standard for what permissions are necessary.
Hierarchy
- class \record_shorten_views_handler_field_hostname extends \views_handler_field
Expanded class hierarchy of record_shorten_views_handler_field_hostname
1 string reference to 'record_shorten_views_handler_field_hostname'
- record_shorten_views_data in ./
record_shorten.views.inc - Implementation of hook_views_data().
File
View source
class record_shorten_views_handler_field_hostname extends views_handler_field {
function options_form(&$form, &$form_state) {
parent::options_form($form, $form_state);
$form['notice'] = array(
'#value' => '<p class="form-item"><strong>' . t('Users must have both the "administer users" and "access site reports" permission to view this field.') . '</strong></p>',
'#weight' => -10,
);
}
function render($values) {
if (!user_access('administer users') || !user_access('access site reports')) {
return;
}
return parent::render($values);
}
}