summaryrefslogtreecommitdiff
path: root/update.php
diff options
context:
space:
mode:
authorJohn Kristensen <[email protected]>2011-02-09 12:50:47 +1100
committerAndrew Dolgov <[email protected]>2011-02-09 14:52:14 +0300
commitd195055341368ca2b480a60b8a62c0c49966d272 (patch)
treeb7e83eba0de2f9fdcced9b97aca68fc68c699667 /update.php
parent8e57cfbeb3ccc0b0770f6baf6a967b0170733b24 (diff)
Allow update.php to be run from outside of the main directory
* Change the update.php working directory to be the main tt-rss application directory so that the script can be run from anywhere without problems. Useful for adding the update.php script to cron.
Diffstat (limited to 'update.php')
-rwxr-xr-xupdate.php1
1 files changed, 1 insertions, 0 deletions
diff --git a/update.php b/update.php
index e0c460273..6be19473f 100755
--- a/update.php
+++ b/update.php
@@ -2,6 +2,7 @@
<?php
define('DISABLE_SESSIONS', true);
+ chdir(dirname($_SERVER['SCRIPT_NAME']));
require_once "functions.php";
require_once "sanity_check.php";
require_once "config.php";