⚠ In case you've missed it, we have migrated to our new website, with a brand new forum. For more details about the migration you can read our blog post for website migration. This is an archived forum. ⚠

  •     

profile picture

hmvc + ci + grocery



bianconeri

bianconeri
  • profile picture
  • Member

Posted 02 May 2013 - 22:21 PM

The paste grocery_crud is a module.

My controller

 

module paste: teste

 

 

<?php
 
if (!defined('BASEPATH'))
    exit('No direct script access allowed');
 
class Test extends MX_Controller {
 
    public function __construct() {
        parent::__construct();
        $this->load->library('grocery_crud/grocery_CRUD');
        $this->load->library('grocery_crud/image_moo');
        $this->load->config('grocery_crud/grocery_crud');
        $this->load->model('grocery_crud/grocery_CRUD_Model');
    }
 
    public function index() {
 
        $output = (object) array('output' => '', 'js_files' => array(), 'css_files' => array());
 
        $crud = new grocery_CRUD();
 
        $crud->set_table('table')
                ->columns('columns)
                ->fields('fields')
                
 
        $output = $crud->render();
 
        echo Modules::run('template/crud', $output);
    }
 
}


Show error in ajax_list_info.

404 Page Not Found

The page you requested was not found.

 

And i try add,edit or another, i have the same error above.


victor

victor
  • profile picture
  • Member

Posted 03 May 2013 - 06:34 AM

first at all you can't use GC in the inexperienced function! look at documentation.

bianconeri

bianconeri
  • profile picture
  • Member

Posted 03 May 2013 - 12:50 PM

I looked the documentation, but i dont find a solution.
How can I fix my problem?
 


victor

victor
  • profile picture
  • Member

Posted 03 May 2013 - 13:27 PM

try to rename the function

bianconeri

bianconeri
  • profile picture
  • Member

Posted 03 May 2013 - 22:07 PM

I got to do work.

My project use two databases.
 

How do I the module load the database right?