Finally!!!
timtimar - December 27, 2006 - 22:53
| Project: | Christmas Snow |
| Version: | 4.7.x-1.x-dev |
| Component: | Miscellaneous |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed |
Jump to:
Description
I cannot get this to work. It installed without error but will not run.
No errors in the log nothing.
Install dir matches the INSTALL.txt.

#1
I have the same problem, if no one comes up with a fix, i'll try calling it through the theme instead of as a module, maybe that will get it to work. But for now, it is not at the top of my list of priorities so I'll just leave things till I have the opportunity to play around with it.
#2
I'm using it on a Windows system, but I don't think this is the reason. It doesn't work both on Firefox and Opera, but the example file provided with the script works.
Thanks for your help, funny idea,
Felix.
#3
It's solved, I got it. Maybe it's not perfectly elegant, but it works fine:
<?php
/*
* Drupal Module: Christmas Snow
* Adds Christmas Snow to your site
*
* @author: introfini <www.josefernandes.pt>
* @modified by felixsmile
*/
function christmas_snow_help($section) {
switch ($section) {
case 'admin/modules#description':
return t('Add Christmas Snow to your site.');
case 'admin/settings/christmas_snow':
return t('Add Christmas Snow to your site.');
}
}
function christmas_snow_menu($may_cache) {
$path = drupal_get_path('module', 'christmas_snow');
$js = drupal_add_js($path . '/script/snowstorm.js');
}
?>
How does it work?
christmas_snow_menu because we want snow everywhere, I decided, and because this is the only way I managed to convince it to work.
In the scriptfile, you adapt this line:
var imagePath = 'christmassnow/snow/'; // relative path to snow imagesand you put the snowflakes in the specified folder (starting from the root folder), i.e. you DON'T put them inside the module folder. The reason is that in the standard install of Drupal 4.7.5, a .htaccess file does not allow to access the modules folder. Simple.
Have fun,
Felix.
#4
#5
I couldn't get this to work under Drupal 5.2 and tried out the previous fix by felixsmile, but found an easier way.
I simply commented out this line from snowstorm.js:
var imagePath = 'image/snow/'; // relative path to snow imagesto be
//var imagePath = 'image/snow/'; // relative path to snow imagesNow it works as it should.
I think this should be mentioned in the README.txt file.