Not adding to the global namespace is always a good idea. E.g using closures or adding functions to an dblclick object.
drupal_add_js('settings') could also be used instead of drupal_add_js('inline').
Not adding to the global namespace is always a good idea. E.g using closures or adding functions to an dblclick object.
drupal_add_js('settings') could also be used instead of drupal_add_js('inline').
Comments
Comment #1
jjeff commentedI try to be conservative with code comments in JS as they add to the download file size to the browser. But, that being said, I probably could stick a little more in there.
As for using the global JS settings provided by Drupal, yes, I should really do that. I wasn't aware of it when I wrote the script. I'll put it on my to-do list.
And if you'd like to whip up a patch, I'd be happy to integrate it.
Comment #2
jjeff commentedFixes committed to HEAD.
Comment #3
(not verified) commented