In a clean Drupal 7, when I install Charts and Graphs, all works fine in Drupal. But then I run some php from the command line which bootstraps Drupal, and it fails to load Charts and Graphs. I'm guessing some sort of unsafe assumption is being made about current working directory.
I run:
define('DRUPAL_ROOT', '/drupal/html');
require_once DRUPAL_ROOT . '/includes/bootstrap.inc';
drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);
and get
PHP Fatal error: require_once(): Failed opening required 'sites/all/modules/charts_graphs/charts_graphs_canvas.class.inc' (include_path='.:/usr/share/pear:/usr/share/php') in /drupal/html/sites/all/modules/charts_graphs/charts_graphs.module on line 12
Fatal error: require_once(): Failed opening required 'sites/all/modules/charts_graphs/charts_graphs_canvas.class.inc' (include_path='.:/usr/share/pear:/usr/share/php') in /drupal/html/sites/all/modules/charts_graphs/charts_graphs.module on line 12
Comments
Comment #2
batje commentedAdded the .module file to the .info file as well. This should not happen anymore (in the dev version)