From d625dfdc6ae2d37756f4dc91084468117bcb0d8b Mon Sep 17 00:00:00 2001 From: Tristan Olive Date: Thu, 18 Jun 2015 09:46:39 -0400 Subject: [PATCH] Updated include_boinc() function to include files relative to the html subdirectory of the BOINC root (DBOINCP-184) --- .../boinc/modules/boincuser/includes/boincuser.helpers.inc | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drupal/sites/default/boinc/modules/boincuser/includes/boincuser.helpers.inc b/drupal/sites/default/boinc/modules/boincuser/includes/boincuser.helpers.inc index 46b66293ba..73373d2be2 100644 --- a/drupal/sites/default/boinc/modules/boincuser/includes/boincuser.helpers.inc +++ b/drupal/sites/default/boinc/modules/boincuser/includes/boincuser.helpers.inc @@ -158,12 +158,15 @@ function require_boinc($libraries) { /** * Include BOINC code - * The path from the BOINC root must be included (e.g. user/file.php) + * The path from the BOINC html root must be included (e.g. user/file.php) */ function include_boinc($file) { if ($include_dir = boinc_get_path()) { + $include_dir .= '/html'; $workingDir = getcwd(); - chdir($include_dir); + $path = dirname($file); + $file = basename($file); + chdir("{$include_dir}/{$path}"); include($file); chdir($workingDir); }