Wednesday, October 2, 2013

Creating a bullet list view for the Tree tutorial

I've been at this for a while and I'm completely new to Cake PHP and full
stack web frameworks period.
I simply want to turn the tree data in the Tree tutorial here
<http://book.cakephp.org/2.0/en/core-libraries/behaviors/tree.html> into a
nice HTML bullet list for learning purposes.

*I have the model*

<?php
class Category extends AppModel {
public $actsAs = array('Tree');
}

?>


*I have the controller*


<?php

class CategoriesController extends AppController {

public function index() {
$data = $this->Category->generateTreeList(null, null, null,
'&nbsp;&nbsp;&nbsp;');

}
}

?>




The view is whats missing.
I tried playing with the set method and adding it to the index action in the
CategoriesController hence assigning it a usable variable in the view.
Nothing seemed to work.

I'm hoping someone could direct me on the right track.

Thank you.



--
View this message in context: http://cakephp.1045679.n5.nabble.com/Creating-a-bullet-list-view-for-the-Tree-tutorial-tp5716765.html
Sent from the CakePHP mailing list archive at Nabble.com.

--
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cake-php+unsubscribe@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.

No comments: