Search code examples
phpcodeigniterhmvccodeigniter-3codeigniter-hmvc

During HMVC installation an error occurred, how to remove?


I am new to codeigniter HMVC structure, following this link for installation. https://bitbucket.org/wiredesignz/codeigniter-modular-extensions-hmvc/src

Have performed all steps but when reached on step 12 it shows error.

Steps:

  1. Start with a clean CI install
  2. Set $config[‘base_url’] correctly for your installation
  3. Access the URL /index.php/welcome => shows Welcome to CodeIgniter
  4. Drop Modular Extensions third_party files into the application/third_party directory
  5. Drop Modular Extensions core files into application/core, the MY_Controller.php file is not required unless you wish to create your own controller extension
  6. Access the URL /index.php/welcome => shows Welcome to CodeIgniter
  7. Create module directory structure application/modules/welcome/controllers
  8. Move controller application/controllers/welcome.php to application/modules/welcome/controllers/welcome.php
  9. Access the URL /index.php/welcome => shows Welcome to CodeIgniter
  10. Create directory application/modules/welcome/views
  11. Move view application/views/welcome_message.php to application/modules/welcome/views/welcome_message.php
  12. Access the URL /index.php/welcome => shows Welcome to CodeIgniter

Error:

Your view folder path does not appear to be set correctly. Please open the following file and correct this: index.php

How to solve it please? is any change need in route/config.index etc? should i copy-paste config folder to each module as well? currently they all are default. My CI version is latest 3.0.3 and in config index_page is empty instead of index.php

$config['index_page'] = '';

also checked by adding index.php instead of empty. one more thing i searched online and also tried by capitalizing View,Controler etc folder names but nothing happened.


Solution

  • try to use this HMVC version :

    https://bitbucket.org/wiredesignz/codeigniter-modular-extensions-hmvc/src/b889da049fd78bd5beff8d7ef70916b60c3d6665?at=codeigniter-3.x