Doubt about Javascript

Rate this topic: Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.1.00 out of 6 based on 1 vote(s)
GK User
Tue Apr 16, 2013 1:49 pm
Reply with quote
Report this post
Hello all!

I´ve a doubt about Javascript. I don´t know too much about this.I´m triying combine files to reduce http request because I´ve about 20 javascript files . So, I did a bit test with 2 files mootools-more and mootools-core using YUI compressor. It combine both files and I called "web.js". After I added to default.php the script to HEAD <script type="text/javascript" src="/min/f=js/web.js"></script>.

When resfreshed to check it, the slideshow and popup cart doesn´t work.May be i´m doing something wrong.Anyone could suggest me how i can combine the files?

Kind regards

PD:I tried to use template option "compression javascript" and it doesn´t work.
User avatar
Expert Boarder

GK User
Wed Apr 17, 2013 8:04 am
Reply with quote
Report this post
PD:I tried to use template option "compression javascript" and it doesn´t work.


What you mean by doesn't work ? Did you have JS conflicts, sometimes you need to exclude some library to avoid problems (usually vm scripts need to be loaded at last).
User avatar
Platinum Boarder

GK User
Wed Apr 17, 2013 11:00 am
Reply with quote
Report this post
Hello bkrztuk,

When i active the option "compression javascript" doesn´t load slideshow,news pro gk4 module,login and cart popup,search module and vm.

And how could I load vm scripts at last?
User avatar
Expert Boarder

GK User
Mon Apr 22, 2013 8:22 am
Reply with quote
Report this post
You need to exclude them in special field under template advanced setting tab. Please look at this article >> http://gavick.com/magazine/dev-update-9.html especially this part :

Using the 'Exclude JS/CSS' option, a user may specify which files have to be switched on within compression – in the case of a greater amount of files , you will have to list them out by separating them with a commas, e.g.: com_k2/css/k2.css, system/js/mootools-core.js.
User avatar
Platinum Boarder


cron