<?php
/**
* @package fabrik
* @version 905 | fabrik_cheesegrits | 2008-05-19 21:21:05 +0200 (Mon, 19 May 2008
* @Copyright (C) Rob Clayburn
* @license GNU/GPL http://www.gnu.org/copyleft/gpl.html
*/
/* MOS Intruder Alerts */
defined( '_VALID_MOS' ) or die( 'Direct Access to this location is not allowed.' );
?>
<!--<h1><?php echo $this->table->label;?></h1>-->
<?php echo $this->table->intro;?>
<form action="<?php echo $this->table->action;?>" method="post" id="<?php echo $this->formid;?>" name="fabrikTable">
<?php if($this->showAdd){?>
<span class="pagenav">
<a href="<?php echo $this->addRecordLink;?>"><?php echo _ADD_RECORD;?></a>
</span>
<?php }?>
<?php if($this->showCSV){?>
<span class="pagenav">
<a href="<?php echo $this->csvLink;?>"><?php echo _EXPORT_TO_CSV;?></a>
</span>
<?php }?>
<?php if($this->showRSS){?>
<span class="pagenav">
<a href="<?php echo $this->rsslink;?>"><?php echo _SUBSCRIBE_RSS;?></a>
</span>
<?php }?>
<?php if($this->showFilters){?>
<table class="filtertable">
<tr>
<th style="text-align:left"><?php echo _SEARCH;?>:</th>
<th style="text-align:right"><a href="#" class="clearFilters"><?php echo _CLEAR ?></a></th>
</tr>
<?php foreach($this->filters as $filter){?>
<tr>
<td><?php echo $filter->label;?>: </td>
<td style="text-align:right;"><?php echo $filter->element;?></td>
</tr>
<?php } ?>
<?php if($this->filter_action != 'onchange') {?>
<tr>
<td colspan="2" style="text-align:right;">
<input type="button" class="button" value="<?php echo _GO;?>" name="filter" />
</td>
</tr>
<?php }?>
</table>
<?php }?>
<br style="clear:both;" />
<br />
<?php if(count($this->rows) == 0){?>
<div class="emptyDataMessage"><?php echo $this->emptyDataMessage;;?></div>
<?php }else{
foreach($this->rows as $gkey => $group){?>
<table class="fabrikTable">
<tr>
<?php foreach($this->headings as $heading){?>
<th><?php echo $heading;?></th>
<?php }?>
</tr>
<?php
$c = 0;
foreach($group as $rkey => $row){ ?>
<tr class="oddrow<?php echo $c;?> <?php echo implode(' ',$this->rowClasses[$gkey][$rkey]); ?> ">
<?php
foreach($this->headings as $heading=>$label){ ?>
<td class="<?php echo $this->cellClasses[$gkey][$rkey][$heading];?>"><?php echo($row->$heading);?></td>
<?php }?>
</tr>
<?php $c = 1-$c;;
}
}?>
<tr class="fabrik_calculations">
<?php
foreach($this->calculations as $cal){
echo "<td>" . $cal->calc ."</td>";
}
?>
</tr>
</table>
<?php echo $this->nav;
if( $this->canDelete ){?>
<label><input type="checkbox" id="table_<?php echo $this->table->id;?>_checkAll" /><?php echo _CHECK_ALL;?></label>
<?php
}
echo $this->deleteButton;
echo " " . $this->emptyButton;?>
<?php }
print_r($this->hiddenFields);?>
</form>