- drupal_add_js(variable_get('pz2_js_path', 'pazpar2/js')
- . '/pz2.js', 'module', 'footer');
+ // D6 seems not to be able to handle external scripts
+ // assume one if path starts with http:
+ // assume alias if path starts with /
+ if (preg_match('/^http:/') || preg_match('/^\//') {
+ drupal_add_js(variable_get('pz2_js_path', 'pazpar2/js')
+ . '/pz2.js', 'module', 'footer', TRUE, TRUE, FALSE);
+ } else {
+ drupal_add_js($path.'/'.variable_get('pz2_js_path', 'pazpar2/js')
+ . '/pz2.js', 'module', 'footer');
+ }