function _rdf_set_field_rel_attribute
Same name in other branches
- 9 core/modules/rdf/rdf.module \_rdf_set_field_rel_attribute()
Transforms the field property attribute into a rel attribute.
1 call to _rdf_set_field_rel_attribute()
- rdf_preprocess_field__node__uid in core/
modules/ rdf/ rdf.module - Implements hook_preprocess_HOOK() for UID field templates.
File
-
core/
modules/ rdf/ rdf.module, line 289
Code
function _rdf_set_field_rel_attribute(&$variables) {
// Swap the regular field property attribute and use the rel attribute
// instead so that it plays well with the RDFa markup when only a link is
// present in the field output, for example in the case of the uid field.
if (!empty($variables['attributes']['property'])) {
$variables['attributes']['rel'] = $variables['attributes']['property'];
unset($variables['attributes']['property']);
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.