Again Javascript on my site

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.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top