function _rdf_set_field_rel_attribute
_rdf_set_field_rel_attribute(&$variables)
Transforms the field property attribute into a rel attribute.
File
- core/modules/rdf/rdf.module, line 286
- Enables semantically enriched output for Drupal sites in the form of RDFa.
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']); } }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!modules!rdf!rdf.module/function/_rdf_set_field_rel_attribute/8.1.x