| 1 |
<?php
|
| 2 |
// $Id $
|
| 3 |
/**
|
| 4 |
* @file views-view-row-unformatted.tpl.php
|
| 5 |
* Simple view template to view unformatted fields from the views query.
|
| 6 |
*
|
| 7 |
* - $view: The view in use.
|
| 8 |
* - $fields: an array of $field objects. Each one contains:
|
| 9 |
* - $field->content: The output of the field.
|
| 10 |
* - $field->raw: The raw data for the field, if it exists. This is NOT output safe.
|
| 11 |
* - $field->class: The safe class id to use.
|
| 12 |
* - $field->handler: The Views field handler object controlling this field. Do not use
|
| 13 |
* var_export to dump this object, as it can't handle the recursion.
|
| 14 |
* - $field->separator: an optional separator that may appear before a field.
|
| 15 |
* - $row: The raw result object from the query, with all data it fetched.
|
| 16 |
*
|
| 17 |
* @ingroup views_templates
|
| 18 |
* @see views_json.views.inc
|
| 19 |
*/
|
| 20 |
|
| 21 |
//print ('template');
|
| 22 |
//print_r($fields);
|
| 23 |
//print_r($row);
|
| 24 |
//print_r($options);
|
| 25 |
//foreach ($fields as $id => $field)
|
| 26 |
// print $id.":".$field->content."\n";
|
| 27 |
|
| 28 |
$field_separator = filter_xss_admin($options['separator']);
|
| 29 |
foreach($row as $field_label => $field_value)
|
| 30 |
$row_unformatted.= $field_label.":".(!is_null($field_value) ? $field_value: "").$field_separator;
|
| 31 |
print rtrim($row_unformatted, $field_separator).PHP_EOL;
|
| 32 |
|
| 33 |
|