some javascripts wont work anymore
aexl - February 9, 2008 - 11:32
| Project: | Javascript Aggregator |
| Version: | 5.x-1.4 |
| Component: | Miscellaneous |
| Category: | bug report |
| Priority: | normal |
| Assigned: | derjochenmeyer |
| Status: | active |
Description
(filing this here although this might be a javascript "bug":)
on my site the collapsible fieldsets of (at least) the new-content page wont work anymore with aggregted javascript turned on (no matter of comment optimasation).
bugfix: exclude /misc/collapse.js
file version:
collapse.js,v 1.10 2007/01/11 03:38:31 unconed
ps: aggregator 0.6 same behaviour
pps: js aggregator rocks!!!

#1
hmmm ... did it work with any prior version of js aggregator? did you clear the cache and tried a hard browswer reload?
the site for which i initially developed js aggregator (www.routebook.com ) had a lot of js intensive modules installed... i have no problems... do you have the jquery update module installed?
#2
what did i do?
- use my site, collapse working
- enable jsaggregator, collapse NOT working
- disable jsaggregator, collapse working again
- exclude collapse.js, enable jsaggregator, collapse still working
so i cannot imagine how this might not be a caching issue.
>did it work with any prior version of js aggregator?
i didnt try any
>do you have the jquery update module installed?
nope. should i or might this be harmful?
i only use jquib which i need for debug
ps: exactly same issue with thickbox module js here
#3
hm... as i said i developed this module for myself and i have dozens of js heavy modules installed including thickbox.... absolutely no problems, collapse working... try installing jquery update its not harmfull at all but...
#4
jscalendar is the next on the list of not working modules.
this is a complete riddle to me. perhaps there is a third module that interferes with others... dontknow.
trying to debug this issue i found a js error on the (firebug) error console.
the short form ist: (long form in attachment)
eval((function (p, a, c, k, e, d) {e = function (c) {return (c < a ? "" : e(parseInt(c / a))) + ((c = c % a) > 35
...
|class|jQuery".split("|"), 0, {})) is not a function
http://mysite.de/files/js/5b50305bdd75252923ea664202363861.js Line 795
(wow, what cryptic evals jquery uses...)
perhaps some javascript-knower might lead me a way to debugging this.
tia!
#5
i use jscalendar on my site and it works ;)
excluding files from aggregation can change the order in which they are called...
if you exclude jquery.js for example it gets included as last which breaks everything... can be tricky
#6
i noticed that the error line above had no trailing semicolon, and was the last line of the module.
so i changed javascript_aggregator.module to insert a semicolon at the start of every new js-filechunk to terminate the preceding filechunk.
now all the said modules seem to work here.
manually patch javascript_aggregator.module 1.1 line 76:
- $contents .= "/* AGGREGATED JS FILE: $scripts_js_file */\n".$data."\n";
+ $contents .= ";/* AGGREGATED JS FILE: $scripts_js_file */\n".$data."\n";
tralalaaaa!
i cannot imagine that this may have negative side-effects, but i might learn from js-knowers...
#7
Actually this was a feature of the first version. Ill add it again in the next version. Thanks!
#8
#9
Automatically closed -- issue fixed for two weeks with no activity.
#10
hi. I am having these problems once I enable jsaggregation:
aggregation breaks collapsible fieldset throughout the site
jscalendar calendar image does not show up under date fields
I tried excluding them but nothing happened.
Sorry to have re-oppened this but this is exactly what I am experiencing.
Chris
#11
Count me in: fivestar, gmap - all js elements on site got lost. Even excluding
all scripts from head did nothing :>
I reverted module to 1.3, as I think there was no significant changes
between 1.3 and 1.4. And waiting...
Szy.
#12
What JavaScript are you using? Are you JSMinifying it? Could you try out 5.x-1.x to see if its fixed?
#13
I am still having the problem with collapse.js not working. I have tried both 5.x.1.4 and 5.x-1.x-dev versions. I tried to exclude the file from aggregation, but that doesn't help either. I am also using jquery if that makes a difference. Any help on this would be greatly appreciated!
#14
Hmm, seems to be working here..... Do you have a link where you're experiencing this?
#15
The site where I'm experiencing the problem is here: www.levantinecenter.org
Thanks!