Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
Installation & Setup
Config Files in Modules
I am starting with a new project and decided to stick with Fuel over Codeigniter, and for the most part things are going smoothly. I have tried loading in some other modules I found on github: shopping cart (
) and Amazon S3 (
). The issue I am having is that when I load these modules the config files are not being read by the \Config:load function. I was able to move the config array into the class itself, but I am wondering if there is a bigger issue of why isn't it loading. Any help getting the configs to load correctly would really help. directory fuel
config.php This works after moving the config array into the cart.php file under classes.
$cart = new \Ecommerce\Cart();
$view = View::factory('welcome/index');
$view->set('items', $cart->items()); Doing a var_dump on any config item returns NULL from a module.
Ecommerce and Amazon S3 are packages, not modules. Also the config.php file is not supposed to be read when loading a module or a package. For packages, the bootstrap.php is executed when the package is added.
Thanks Julian, that fixed the the problem.
Add a Comment
It looks like you're new here. If you want to get involved, click one of these buttons!
Apply for Membership
↳ Job Board
↳ Installation & Setup
↳ Tips and Tutorials
↳ Code share
In this Discussion