views-view-fields--nodequeue-6--block.tpl.php

Default simple view template to all the fields as a row.

  • $view: The view in use.
  • $fields: an array of $field objects. Each one contains:
    • $field->content: The output of the field.
    • $field->raw: The raw data for the field, if it exists. This is NOT output safe.
    • $field->class: The safe class id to use.
    • $field->handler: The Views field handler object controlling this field. Do not use var_export to dump this object, as it can't handle the recursion.
    • $field->inline: Whether or not the field should be inline.
    • $field->inline_html: either div or span based on the above flag.
    • $field->wrapper_prefix: A complete wrapper containing the inline_html to use.
    • $field->wrapper_suffix: The closing tag for the wrapper.
    • $field->separator: an optional separator that may appear before a field.
    • $field->label: The wrap label text to use.
    • $field->label_html: The full HTML of the label to use including configured element type.
  • $row: The raw result object from the query, with all data it fetched.

Globals

Namesort descending Description
$tmp_featured_row @file Default simple view template to all the fields as a row.

File

profiles/cis/themes/cis-theme/templates/views-view-fields--nodequeue-6--block.tpl.php
View source
  1. /**
  2. * @file
  3. * Default simple view template to all the fields as a row.
  4. *
  5. * - $view: The view in use.
  6. * - $fields: an array of $field objects. Each one contains:
  7. * - $field->content: The output of the field.
  8. * - $field->raw: The raw data for the field, if it exists. This is NOT output safe.
  9. * - $field->class: The safe class id to use.
  10. * - $field->handler: The Views field handler object controlling this field. Do not use
  11. * var_export to dump this object, as it can't handle the recursion.
  12. * - $field->inline: Whether or not the field should be inline.
  13. * - $field->inline_html: either div or span based on the above flag.
  14. * - $field->wrapper_prefix: A complete wrapper containing the inline_html to use.
  15. * - $field->wrapper_suffix: The closing tag for the wrapper.
  16. * - $field->separator: an optional separator that may appear before a field.
  17. * - $field->label: The wrap label text to use.
  18. * - $field->label_html: The full HTML of the label to use including
  19. * configured element type.
  20. * - $row: The raw result object from the query, with all data it fetched.
  21. *
  22. * @ingroup views_templates
  23. */
  24. global $tmp_featured_row;
  25. $tmp_featured_row++;
  26. foreach ($fields as $id => $field) {
  27. if ($tmp_featured_row == 1) {
  28. if ($id == 'field_news_image') {
  29. print $field->wrapper_prefix ."\n";
  30. print $field->label_html ."\n";
  31. print $field->content ."\n";
  32. print $field->wrapper_suffix ."\n";
  33. print '</div><div class="columns small-12 large-6">';
  34. }
  35. else if ($id == 'field_color') {
  36. print $field->content ."\n";
  37. }
  38. else if($id == 'title') {
  39. print $field->wrapper_prefix ."\n";
  40. print $field->label_html ."\n";
  41. print '<h2 class="featured-front-page-h2-title">'. $field->content ."</h2>\n";
  42. print $field->wrapper_suffix ."\n";
  43. }
  44. else {
  45. print $field->wrapper_prefix ."\n";
  46. print $field->label_html ."\n";
  47. print $field->content ."\n";
  48. print $field->wrapper_suffix ."\n";
  49. }
  50. }
  51. else {
  52. if ($id != 'field_news_image' && $id != 'field_subtext') {
  53. print $field->wrapper_prefix ."\n";
  54. print $field->label_html ."\n";
  55. print $field->content ."\n";
  56. print $field->wrapper_suffix ."\n";
  57. }
  58. }
  59. }

Related topics