Julian Bond <julian_bond@voidstar.com> Tue, 1 Mar 2005 18:41:15
Hmmm. Maybe I shouldn't be calling functions in common.inc during the module_init hook.
I was trying to add a style sheet and a javascript file to the <head> of every page using quicktags_init() as an example.
I think there may be a sequence problem here Index.php include_once 'includes/bootstrap.inc'; drupal_page_header(); include_once 'includes/common.inc'; If the cache is turned on drupal_page_header() calls bootstrap_invoke_all('init'); which calls module_load($module); module_invoke($module, $op); So module functions can be called before common.inc is loaded, but only if cache is turned on and it's a guest user coming in. And it seems quite possible that module writers would use functions that are only available *after* common.inc is loaded. -- Julian Bond Email&MSM: julian.bond at voidstar.com Webmaster: http://www.ecademy.com/ Personal WebLog: http://www.voidstar.com/ M: +44 (0)77 5907 2173 T: +44 (0)192 0412 433 S: callto://julian.bond/