| 1 | <?php |
|---|
| 2 | echo $html->addCrumb('Control Panel', '/admin/entries/start'); |
|---|
| 3 | echo $html->getCrumbs(' / '); |
|---|
| 4 | |
|---|
| 5 | echo $html->div('title_section', __('Polls', true)); |
|---|
| 6 | echo $html->link($html->image('actions/new.png', array('alt'=>__('Add new', true), 'title'=>__('Add new', true))),'/admin/polls/add/', null, null, false); |
|---|
| 7 | ?> |
|---|
| 8 | <table class="tbadmin"> |
|---|
| 9 | <?php |
|---|
| 10 | $th = array (__('Edit', true), __('Question', true), __('Created', true), __('Status', true), __('Delete', true)); |
|---|
| 11 | |
|---|
| 12 | echo $html->tableHeaders($th, array('style'=>'text-align:center')); |
|---|
| 13 | |
|---|
| 14 | foreach ($data as $key=>$val): |
|---|
| 15 | $status = ($val['Poll']['status'] == 0) ? __('Draft', true) : __('Published', true); |
|---|
| 16 | $tr = array ( |
|---|
| 17 | $gags->sendEdit($val['Poll']['id'], 'polls'), |
|---|
| 18 | $val['Poll']['question'], |
|---|
| 19 | $val['Poll']['created'], |
|---|
| 20 | $html->link($status, '/admin/polls/change/'.$val['Poll']['id'].'/'.$val['Poll']['status']), |
|---|
| 21 | $gags->confirmDel($val['Poll']['id'], 'polls') |
|---|
| 22 | ); |
|---|
| 23 | echo $html->tableCells($tr, array("class"=>"altRow", "onmouseover"=>"this.className='highlight'", "onmouseout"=>"this.className='altRow'"), |
|---|
| 24 | array('class'=>'evenRow',"onmouseover"=>"this.className='highlight'", "onmouseout"=>"this.className='evenRow'")); |
|---|
| 25 | endforeach; |
|---|
| 26 | ?> |
|---|
| 27 | </table> |
|---|