21278 Posts in 5728 Topics by 2599 members
|
Page:
1
|
Go to End | |
| Author | Topic: | 896 Views |
-
Dont't want to load useless JS files

31 May 2010 at 11:05pm
SS loads a bunch of JS files at the end of my pages (Prototype, behaviour.js, i18n.js ...).
But I really don't need them on my page. It just cranks up download time for users. Where do I fix that?
-
Re: Dont't want to load useless JS files

1 June 2010 at 3:05am
In Page_Controller I use this for excluding prototype and thirdparty scripts, like userforms
public function init() {
parent::init();
Requirements::block('sapphire/thirdparty/jquery/jquery.js');
Requirements::block('userforms/thirdparty/jquery-validate/jquery.validate.min.js');
Validator::set_javascript_validation_handler('none');
} -
Re: Dont't want to load useless JS files

1 June 2010 at 10:26pm
patte, thanks for your help. You saved my users a lot of traffic
-
Re: Dont't want to load useless JS files

3 June 2010 at 7:53pm
The search field wants to load lost of validation js. You can kill those in your _config file with the following line:
Validator::set_javascript_validation_handler('none');
| 896 Views | ||
|
Page:
1
|
Go to Top |


