summaryrefslogtreecommitdiff
path: root/backend.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2005-11-23 19:08:01 +0100
committerAndrew Dolgov <[email protected]>2005-11-23 19:08:01 +0100
commitcce28758b293bffa184f0617083691285a197032 (patch)
tree170c8b169df2e22b78389c31d66855c5db335a4c /backend.php
parent721064e1a2c463f151751e4f0dad0779077445b2 (diff)
debug request variable sets error_reporting to E_ALL
Diffstat (limited to 'backend.php')
-rw-r--r--backend.php16
1 files changed, 12 insertions, 4 deletions
diff --git a/backend.php b/backend.php
index cdad2083f..327030e32 100644
--- a/backend.php
+++ b/backend.php
@@ -1,6 +1,14 @@
<?
session_start();
+ if ($_GET["debug"]) {
+ define('DEFAULT_ERROR_LEVEL', E_ALL);
+ } else {
+ define('DEFAULT_ERROR_LEVEL', E_ERROR | E_WARNING | E_PARSE);
+ }
+
+ error_reporting(DEFAULT_ERROR_LEVEL);
+
$op = $_REQUEST["op"];
if ((!$op || $op == "rpc" || $op == "globalUpdateFeeds") && !$_REQUEST["noxml"]) {
@@ -20,7 +28,7 @@
exit;
}
- define(SCHEMA_VERSION, 2);
+ define('SCHEMA_VERSION', 2);
require_once "sanity_check.php";
require_once "config.php";
@@ -111,7 +119,7 @@
print "<label id=\"$id\" counter=\"$count\"/>";
- error_reporting (E_ERROR | E_WARNING | E_PARSE);
+ error_reporting (DEFAULT_ERROR_LEVEL);
}
}
@@ -227,7 +235,7 @@
$class .= "Unread";
}
- error_reporting (E_ERROR | E_WARNING | E_PARSE);
+ error_reporting (DEFAULT_ERROR_LEVEL);
printFeedEntry(-$line["id"]-11,
$class, $line["description"], $count, "images/label.png", $link);
@@ -836,7 +844,7 @@
$lnum = 0;
- error_reporting (E_ERROR | E_WARNING | E_PARSE);
+ error_reporting (DEFAULT_ERROR_LEVEL);
$num_unread = 0;