Prevent multiple inclusions of jQuery UI
Re: Prevent multiple inclusions of jQuery UI
What happen if one extension turn it off for some reason? There may be a conflict as to if it should be on or not.
Re: Prevent multiple inclusions of jQuery UI
The extension is not validated?*Daniel wrote:What happen if one extension turn it off for some reason?
Re: Prevent multiple inclusions of jQuery UI
Well yes but what if there a need to have it disabled because someone decided to use a different library for some reason? (just thinking outside the box, it may not happen but you never know)
Re: Prevent multiple inclusions of jQuery UI
noConflict()?
-
- Registered User
- Posts: 523
- Joined: Sat Apr 22, 2006 10:29 pm
- Contact:
Re: Prevent multiple inclusions of jQuery UI
Having it in the core (+1) and using the above mentioned solution seems like the best and most logical way to go.nickvergessen wrote:... What we could do easy is something like:
<!-- IF $LOAD_JQUERY_UI --><!-- INCLUDEJS jquery.ui.js --><!-- ENDIF -->
This way, ext authors can easily load it (by just setting $LOAD_JQUERY_UI to true) and it does not waste resources when its not used.
What's wrong with this solution?
Re: Prevent multiple inclusions of jQuery UI
I made a mod for this problem you may interested in:
https://www.phpbb.com/customise/db/mod/ ... for_phpbb/
https://www.phpbb.com/customise/db/mod/ ... for_phpbb/
- nickvergessen
- Former Team Member
- Posts: 733
- Joined: Sun Oct 07, 2007 11:54 am
- Location: Stuttgart, Germany
- Contact:
Re: Prevent multiple inclusions of jQuery UI
No, its the other way round. Its included in the core and you set that var, when you want the core to load it.imkingdavid wrote:Of course, you need to set $LOAD_JQUERY_UI once you've included it.
Member of the Development-Team — No Support via PM
- imkingdavid
- Registered User
- Posts: 1050
- Joined: Thu Jul 30, 2009 12:06 pm
Re: Prevent multiple inclusions of jQuery UI
Ahh, I see. I misunderstood. That works better.
Re: Prevent multiple inclusions of jQuery UI
OK, registered with my own nick, works a lot better i think...
This thread stopped about six weeks ago and i haven';t seen any RFC or anything suggesting that there is a follow-up on this topic. I would like the jQueryUI to be included in the core, simply because the pros outweigh the cons a lot.
Therre is a lot of talk in the new 3.1 series to ajaxify things, there are ajaxified alerts already in (some) place(s) etc. If all ajax that will be needed for all those functions bundle into a selective jQuery bundle then it wouldn't be any "heavier" than all the js that is currently developed or will be developed in the near future.
So i am kind of curious what is decided here...
This thread stopped about six weeks ago and i haven';t seen any RFC or anything suggesting that there is a follow-up on this topic. I would like the jQueryUI to be included in the core, simply because the pros outweigh the cons a lot.
Therre is a lot of talk in the new 3.1 series to ajaxify things, there are ajaxified alerts already in (some) place(s) etc. If all ajax that will be needed for all those functions bundle into a selective jQuery bundle then it wouldn't be any "heavier" than all the js that is currently developed or will be developed in the near future.
So i am kind of curious what is decided here...
- Darkness_demoN
- Registered User
- Posts: 89
- Joined: Mon Jul 29, 2013 1:48 pm
- Contact:
Re: Prevent multiple inclusions of jQuery UI
+1
I thin it will be better to be include in the core. There are alot of jquery functions over the internet. At now almost evry site use jquery inside. I think ( and i hope ) alot of theme makers will make themes with good animations wich need to use jquery.
So that are my reasons
I thin it will be better to be include in the core. There are alot of jquery functions over the internet. At now almost evry site use jquery inside. I think ( and i hope ) alot of theme makers will make themes with good animations wich need to use jquery.
So that are my reasons