Love Fuel?    Donate

FuelPHP Forums

Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
No output (white page) on syntax or some other error
  • I have found related question in some old topic but with no answer... Sometimes fuel request generates no output, only renders white page. Then you go for searching you see sometimes you made a syntax error... Well the problem is this is a pain to find. Especially in this modular, package code with N classes and so on. Is there a way to fix this?
  • Enable error reporting and display errors. This is enabled by default in your index.php. When in development mode FuelPHP shows you all errors including a code snippit and a backtrace, in production mode you only get a generic message, but the error will be logged. In no circumstance will you get a blank page. So either you've disabled error reporting and/or display errors somewhere, or it's turned off in your php.ini. Or perhaps you're using an old or non-standard index.php file?
  • Nope. I usually get the Fuel error page with all the back-trace and so on, but sometimes the output is simply blank white page (with no HTML source). And this makes it extremely hard to trace the error... Once I got this because I made a syntax error in IF ELSE sentence. Right now I am having a deeper problem in one of the packages, but cant find out where. The logs also don't tell me a thing about this. I am using the standard index.php file that comes with latest release. My config.php
     'errors'  => array(
      // Which errors should we show, but continue execution?
      'continue_on'  => array(E_NOTICE, E_WARNING, E_DEPRECATED, E_STRICT),
      // How many errors should we show before we stop showing them? (prevents out-of-memory errors)
      'throttle'     => 10,
      // Should notices from Error::notice() be shown?
      'notices'      => true,
     ),
    
     'log_threshold'    => Fuel::L_ALL,
     'log_path'         => APPPATH.'logs/',
     'log_date_format'  => 'Y-m-d H:i:s',
    
    

    My index.php
    error_reporting(-1);
    ini_set('display_errors', 1);
    
  • The only reason for a blank page I can think of is that the code actually executes, but there is no data in the response. Parsing errors, warnings, notices, I get them all. I have never seen such an issue...

Howdy, Stranger!

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

In this Discussion