thilip.xandy Posted February 3, 2014 Share Posted February 3, 2014 How to get list of product categories and with all its sub category. Link to comment Share on other sites More sharing options...
vekia Posted February 3, 2014 Share Posted February 3, 2014 hello for what purposes you want it? also where? you want to get a code in php? or sql? please shed some more light on your question thanks in advance Link to comment Share on other sites More sharing options...
thilip.xandy Posted February 4, 2014 Author Share Posted February 4, 2014 (edited) In module .tpl file, i want to list all the categories with its sub category in form. Edited February 4, 2014 by thilip.xandy (see edit history) Link to comment Share on other sites More sharing options...
vekia Posted February 4, 2014 Share Posted February 4, 2014 if you mean something like that: the definition of this field looks like: array( 'type' => 'categories', 'label' => $this->l('Parent category:'), 'name' => 'id_parent', 'values' => array( 'trads' => array( 'Root' => $root_category, 'selected' => $this->l('Selected'), 'Collapse All' => $this->l('Collapse All'), 'Expand All' => $this->l('Expand All') ), 'selected_cat' => $selected_cat, 'input_name' => 'id_parent', 'use_radio' => true, 'use_search' => false, 'disabled_categories' => array(4), 'top_category' => Category::getTopCategory(), 'use_context' => true, ) ), Link to comment Share on other sites More sharing options...
thilip.xandy Posted February 5, 2014 Author Share Posted February 5, 2014 Hi vekia, Your abosoulutly correct, how I'll display this in my tpl file. I have posted in my php file and display with help of assign and it's through an error. check with below, Notice: Array to string conversion in G:\xampp\htdocs\project\classes\Dispatcher.php on line 637Fatal error: Call to undefined method marketPlaceAddProductModuleFrontController::l() in G:\xampp\htdocs\project\modules\marketplace\controllers\front\addProduct.php on line 211 Link to comment Share on other sites More sharing options...
Recommended Posts