diff options
author | John Kristensen <[email protected]> | 2011-02-09 12:50:47 +1100 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2011-02-09 14:52:14 +0300 |
commit | d195055341368ca2b480a60b8a62c0c49966d272 (patch) | |
tree | b7e83eba0de2f9fdcced9b97aca68fc68c699667 | |
parent | 8e57cfbeb3ccc0b0770f6baf6a967b0170733b24 (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.
-rwxr-xr-x | update.php | 1 |
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"; |