annotate sites/all/modules/semanticviews/semanticviews-view-fields.tpl.php @ 4:ce11bbd8f642

added modules
author danieleb <danielebarchiesi@me.com>
date Thu, 19 Sep 2013 10:38:44 +0100
parents
children
rev   line source
danielebarchiesi@4 1 <?php
danielebarchiesi@4 2 /**
danielebarchiesi@4 3 * @file semanticviews-view-fields.tpl.php
danielebarchiesi@4 4 * Default simple view template to display all the fields as a row. The template
danielebarchiesi@4 5 * outputs a full row by looping through the $fields array, printing the field's
danielebarchiesi@4 6 * HTML element (as configured in the UI) and the class attributes. If a label
danielebarchiesi@4 7 * is specified for the field, it is printed wrapped in a <label> element with
danielebarchiesi@4 8 * the same class attributes as the field's HTML element.
danielebarchiesi@4 9 *
danielebarchiesi@4 10 * - $view: The view in use.
danielebarchiesi@4 11 * - $fields: an array of $field objects. Each one contains:
danielebarchiesi@4 12 * - $field->content: The output of the field.
danielebarchiesi@4 13 * - $field->raw: The raw data for the field, if it exists. This is NOT output
danielebarchiesi@4 14 * safe.
danielebarchiesi@4 15 * - $field->element_type: The HTML element wrapping the field content and
danielebarchiesi@4 16 * label.
danielebarchiesi@4 17 * - $field->attributes: An array of attributes for the field wrapper.
danielebarchiesi@4 18 * - $field->handler: The Views field handler object controlling this field.
danielebarchiesi@4 19 * Do not use var_export to dump this object, as it can't handle the
danielebarchiesi@4 20 * recursion.
danielebarchiesi@4 21 * - $row: The raw result object from the query, with all data it fetched.
danielebarchiesi@4 22 *
danielebarchiesi@4 23 * @see template_preprocess_semanticviews_view_fields()
danielebarchiesi@4 24 * @ingroup views_templates
danielebarchiesi@4 25 * @todo Justify this template. Excluding the PHP, this template outputs angle
danielebarchiesi@4 26 * brackets, the label element, slashes and whitespace.
danielebarchiesi@4 27 */
danielebarchiesi@4 28 ?>
danielebarchiesi@4 29 <?php foreach ($fields as $id => $field): ?>
danielebarchiesi@4 30
danielebarchiesi@4 31 <?php if ($field->element_type): ?>
danielebarchiesi@4 32 <<?php print $field->element_type; ?><?php print drupal_attributes($field->attributes); ?>>
danielebarchiesi@4 33 <?php endif; ?>
danielebarchiesi@4 34
danielebarchiesi@4 35 <?php if ($field->label): ?>
danielebarchiesi@4 36
danielebarchiesi@4 37 <?php if ($field->label_element_type): ?>
danielebarchiesi@4 38 <<?php print $field->label_element_type; ?><?php print drupal_attributes($field->label_attributes); ?>>
danielebarchiesi@4 39 <?php endif; ?>
danielebarchiesi@4 40
danielebarchiesi@4 41 <?php print $field->label; ?>:
danielebarchiesi@4 42
danielebarchiesi@4 43 <?php if ($field->label_element_type): ?>
danielebarchiesi@4 44 </<?php print $field->label_element_type; ?>>
danielebarchiesi@4 45 <?php endif; ?>
danielebarchiesi@4 46
danielebarchiesi@4 47 <?php endif; ?>
danielebarchiesi@4 48
danielebarchiesi@4 49 <?php print $field->content; ?>
danielebarchiesi@4 50
danielebarchiesi@4 51 <?php if ($field->element_type): ?>
danielebarchiesi@4 52 </<?php print $field->element_type; ?>>
danielebarchiesi@4 53 <?php endif; ?>
danielebarchiesi@4 54
danielebarchiesi@4 55 <?php endforeach; ?>