07.18
php
saved
Martz
Note
Martz did not leave a note
Martz did not leave a note
- <?php
- class TagsController extends AppController {
- var $name = 'Tags';
- function index() {
- $this->Tag->recursive = 0;
- $this->set('tags', $this->paginate());
- }
- function add() {
- $this->Tag->create();
- if ($this->Tag->save($this->data)) {
- $this->Session->setFlash(__('The Tag has been saved', true));
- } else {
- $this->Session->setFlash(__('The Tag could not be saved. Please, try again.', true));
- }
- }
- $products = $this->Tag->Product->find('list');
- }
- function edit($id = null) {
- $this->Session->setFlash(__('Invalid Tag', true));
- }
- if ($this->Tag->save($this->data)) {
- $this->Session->setFlash(__('The Tag has been saved', true));
- } else {
- $this->Session->setFlash(__('The Tag could not be saved. Please, try again.', true));
- }
- }
- $this->data = $this->Tag->read(null, $id);
- }
- $products = $this->Tag->Product->find('list');
- }
- ***************** VIEW FILES **********************
- <div class="settings form">
- <fieldset>
- <legend><?php __('Edit Setting');?></legend>
- <?php
- ?>
- </fieldset>
- </div>
- <div class="actions">
- <ul>
- <li><?php echo $html->link(__('List Attachments', true), array('controller'=> 'attachments', 'action'=>'index')); ?> </li>
- <li><?php echo $html->link(__('New Thumb', true), array('controller'=> 'attachments', 'action'=>'add')); ?> </li>
- </ul>
- </div>
Parsed in 0.209 seconds, using GeSHi 1.0.7.14