debug() public static method

Debug method. Allows quick shortcut to produce debug output into a temporary file.
public static debug ( mixed $event = null, string $fname = null, boolean $backtrace = true )
$event mixed Item to log.
$fname string Filename to log to. If empty, logs to 'horde_debug.txt' in the PHP temporary directory.
$backtrace boolean Include backtrace information?
Esempio n. 1
0
File: Ical.php Progetto: horde/horde
 /**
  * Updates an existing event in the backend.
  *
  * @param Kronolith_Event $event  The event to save.
  *
  * @return string  The event id.
  * @throws Horde_Mime_Exception
  * @throws Kronolith_Exception
  */
 protected function _updateEvent(Kronolith_Event $event)
 {
     $response = $this->_saveEvent($event);
     if (!in_array($response['statusCode'], array(200, 204))) {
         // To find out if $response still contains the final URL after the refactoring
         Horde::debug($response);
         Horde::log(sprintf('Failed to update event on remote calendar: url = "%s", status = %s', '', $response['body']), 'INFO');
         throw new Kronolith_Exception(_("The event could not be updated on the remote server."));
     }
     return $event->id;
 }