Hi,

as soon as i installed your module, I keep getting code conflicts with the Flag and OG modules... see error bellow:

Warning: include_once(sites/all/modules/flag/includes/flag.token.inc) [function.include-once]: failed to open stream: No such file or directory in flag_init() (line 180 of /home/idev7615/public_html/rms/sites/all/modules/flag/flag.module).
Warning: include_once() [function.include]: Failed opening 'sites/all/modules/flag/includes/flag.token.inc' for inclusion (include_path='.:/usr/local/php52/pear') in flag_init() (line 180 of /home/idev7615/public_html/rms/sites/all/modules/flag/flag.module).
Warning: include_once(sites/all/modules/flag/includes/flag.actions.inc) [function.include-once]: failed to open stream: No such file or directory in flag_init() (line 181 of /home/idev7615/public_html/rms/sites/all/modules/flag/flag.module).

any ideas would be really appreciated.

Thanks
Hashim

CommentFileSizeAuthor
#3 drupal_root.patch1.61 KBjeffersonjhunt

Comments

cesarmiquel’s picture

Hey! We are seeing the same problem on our site also. In our case we are installing all our modules at sites/all/modules/contrib. The bowob module seems to assume it is installed in sites/all/modules so we installed it there. Maybe the problem is coming from this. Where do you have it installed?

cesarmiquel’s picture

I fixed the warnings by adding two lines of code to the bowob/bowob.php file. They basically set the include_path() correctly. I'm including the code here. It seems to work ok and the warnings are removed.

<?php
// $Id$

/**
 * @file bowob.php
 *
 * Entry point for BoWoB server and client.
 */

// Next two lines depend on the path of this file: /sites/all/modules/bowob/bowob.php
$_SERVER['SCRIPT_NAME'] = $_SERVER['PHP_SELF'] = substr($_SERVER['SCRIPT_NAME'], 0, -33) . 'index.php';
define('DRUPAL_ROOT', dirname(dirname(dirname(dirname(dirname(realpath(__FILE__)))))));

// Add DRUPAL_ROOT to include path.                           // <-- New line
set_include_path( get_include_path() . ':' . DRUPAL_ROOT );   // <-- New line

require(DRUPAL_ROOT . '/includes/bootstrap.inc');
drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);
jeffersonjhunt’s picture

StatusFileSize
new1.61 KB

Here is a patch based on the CKEditor code for finding DRUPAL_ROOT and setting the include paths correctly and bootstrapping. This fixes issues with flag.