Again Javascript on my site

Submitted by fabio on Thu, 2007-02-15 01:03.

As soon as I ported this website to Drupal 5.X I noticed that all the Javascript cool stuff where no more available...

I investigated the problem: looks like in 5.X themes it's available a variable called $scripts which holds javascript imports.

Without printing this variable into the head section of the theme all the Javascript does not work anymore.

Simply adding
<?php print $scripts; ?>
in the head tag of the theme fixed the problem.

Refer to the Converting 4.7.x themes to 5.x page on drupal.org handbook for more informations and further theming changes.

Hi fabio! The correct

Submitted by jbrown (not verified) on Tue, 2007-02-20 06:06.

Hi fabio!

The correct function to use is drupal_get_js().

Your website is suffering from this bug: http://drupal.org/node/114387

You should install the Distributed authentication feature in the drupal module so people don't have to enter their details when commenting.

Jonny

Thanks for the hints and for

Submitted by fabio on Tue, 2007-02-20 22:59.

Thanks for the hints and for reporting the bug with captcha.

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd> <pre> <img> <h2> <h3> <h4> <b>
  • Lines and paragraphs break automatically.
  • Images can be added to this post.
  • You may use [inline:xx] tags to display uploaded files or images inline.

More information about formatting options

7 + 8 =
Solve this simple math problem and enter the result. E.g. for 1+3, enter 4.