You are here

function fb_report_exception in Drupal for Facebook 5

Exception handler for PHP5 exceptions.

1 string reference to 'fb_report_exception'
fb_api_init in ./fb.module
Include the necessary facebook-platform code and initialize the API object.

File

./fb.module, line 593

Code

function fb_report_exception($exception) {
  $message = t('Facebook API exception %message.  !trace', array(
    '%message' => $exception
      ->getMessage(),
    '!trace' => '<pre>' . $exception
      ->getTraceAsString() . '</pre>',
  ));
  watchdog('fb', $message, WATCHDOG_ERROR);

  //drupal_set_message($message, 'error');
  print $message;
  print "<pre>\$_REQUEST:\n";
  print_r($_REQUEST);
  print "\n\nREQUEST_URI:\n" . $_SERVER['REQUEST_URI'];
  print "</pre>";
}