line 1062 on taxonomy_vtn.pages.inc tries to include (require_once) a file, without giving the correct path

warning: taxonomy_vtn_show_nodes() [function.taxonomy-vtn-show-nodes]: open_basedir restriction in effect. File(/taxonomy_vtn_overwrites.inc.php) is not within the allowed path(s): (/var/www/vhosts/disnox.pt/httpdocs:/tmp) in /var/www/vhosts/disnox.pt/httpdocs/sites/all/modules/taxonomy_vtn/taxonomy_vtn.pages.inc on line 1062.

i suggest changing line 1062:
require_once('taxonomy_vtn_overwrites.inc.php');

into:
$taxonomy_vtn_path = drupal_get_path('module', 'taxonomy_vtn');
require_once('$taxonomy_vtn/taxonomy_vtn_overwrites.inc.php');

(put $taxonomy_vtn_path somewhere in the start of taxonomy_vtn.module so it can be read by any php file in the vtn package)

Comments

lpalgarvio’s picture

correction:
$taxonomy_vtn_path = drupal_get_path('module', 'taxonomy_vtn');
require_once('$taxonomy_vtn_path/taxonomy_vtn_overwrites.inc.php');

lpalgarvio’s picture

oops my bad again:S

$taxonomy_vtn_path = drupal_get_path('module', 'taxonomy_vtn');
require_once("$taxonomy_vtn_path/taxonomy_vtn_overwrites.inc.php");

needed double quotes because of the variable

sorry! im tired:p

AlexisWilke’s picture

Assigned: Unassigned » AlexisWilke
Status: Active » Fixed

LPCA,

Yes. You are tired. 8-)

I already checked in the correct fix. You want to use the drupal_load_module() function. It is used a little further in the same file.

It will be in the -dev within 12 hours.

Thank you for reporting and taking the time to present a fix!
Alexis Wilke

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.