Re: [問題] jquery ui 與 jquery tools 共存

看板Ajax作者 (沉默是金。)時間14年前 (2011/03/08 07:46), 編輯推噓2(205)
留言7則, 2人參與, 最新討論串2/2 (看更多)
※ 引述《mesak (米沙)》之銘言: : http://jqueryui.com/ : 與 : http://flowplayer.org/tools/ : 兩者很多共通函式 都用一樣的命名 : 除了改函式名稱,有辦法讓 兩者共存嗎? : http://flowplayer.org/tools/forum/20/26331 : 目前 只看到這個方式 : $("#tabs").uitabs(); // $.ui.tabs : $(".tabs").tabs(); // $.tools.tabs : 不改核心 更換 名稱 1.5 新出的 jQuery subset 或許可以解決這問題? 不過還是會需要改一些code,但相對原本的作法比起來,簡單一些了。 -- I am a person, and I am always thinking . Thinking in love , Thinking in life , Thinking in why , Thinking in worth. I can't believe any of what , I am just thinking then thinking , but worst of all , most of mine is thinking not actioning... -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 72.21.245.243

03/08 09:58, , 1F
不懂.... 官方沒看到 這個 函式 是寫法嗎?
03/08 09:58, 1F

03/08 11:02, , 2F

03/08 11:03, , 3F
適合用不同 jQuery context 綁不同 plug-in。
03/08 11:03, 3F

03/08 12:29, , 4F
var jTools = jQuery.sub();
03/08 12:29, 4F

03/08 12:30, , 5F
jTools.fn.tabs = $.fn.tabs
03/08 12:30, 5F

03/08 12:30, , 6F
delete $.fn.tabs;
03/08 12:30, 6F

03/08 12:30, , 7F
解決了,感謝 新功能真方便~
03/08 12:30, 7F
文章代碼(AID): #1DTMuwJl (Ajax)
討論串 (同標題文章)
文章代碼(AID): #1DTMuwJl (Ajax)