Love Fuel?    Donate

FuelPHP Forums

Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
how to open profiling and caching in controller?
  • how to open profiling and caching in controller?
    it is not work
    \Config::set('profiling', true);
    
  • i find http://fuelphp.com/forums/topics/view/5945
    but if i want to set profiling , not change config.php how can i do?
    sometimes i need debug by admin,but not all users.
    also cache_lifetime, caching....
  • You can not alter certain config values at runtime, as they are used in the FuelPHP boot process. Profiling is such a setting. You will have to add code to your config file to determine the value to return instead of returning a fixed value. Config files are normal PHP files, so you can add to it what you want.
    // this works find in a config file
    $loggedin = \Auth::check();
    
    return array(
        'setting' => $loggedin ? 'Yes' : 'No',
    );
    
  • thank you ,good idea

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion