課程
/前端開(kāi)發(fā)
/Bootstrap
/玩轉(zhuǎn)Bootstrap(基礎(chǔ))
使用了這種方法,不需要引入javascript腳本了吧
2015-01-29
源自:玩轉(zhuǎn)Bootstrap(基礎(chǔ)) 8-7
正在回答
沒(méi)腳本誰(shuí)來(lái)幫你執(zhí)行這些.... 這個(gè)肯定是要的,區(qū)別在于這里面處理了
http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.js
自己去上面這個(gè)js文件里面找modal.js,里面有這一段js
$(document).on('click.bs.modal.data-api',?'[data-toggle="modal"]',?function?(e)?{ ???var?$this???=?$(this) ???var?href????=?$this.attr('href') ???var?$target?=?$($this.attr('data-target')?||?(href?&&?href.replace(/.*(?=#[^\s]+$)/,?'')))?//?strip?for?ie7 ???var?option??=?$target.data('bs.modal')???'toggle'?:?$.extend({?remote:?!/#/.test(href)?&&?href?},?$target.data(),?$this.data()) ???if?($this.is('a'))?e.preventDefault() ???$target.one('show.bs.modal',?function?(showEvent)?{ ?????if?(showEvent.isDefaultPrevented())?return?//?only?register?focus?restorer?if?modal?will?actually?get?shown ?????$target.one('hidden.bs.modal',?function?()?{ ???????$this.is(':visible')?&&?$this.trigger('focus') ?????}) ???}) ???Plugin.call($target,?option,?this) ?})
function?Plugin(option,?_relatedTarget)?{ ????return?this.each(function?()?{ ??????var?$this???=?$(this) ??????var?data????=?$this.data('bs.modal') ??????var?options?=?$.extend({},?Modal.DEFAULTS,?$this.data(),?typeof?option?==?'object'?&&?option) ??????if?(!data)?$this.data('bs.modal',?(data?=?new?Modal(this,?options))) ??????if?(typeof?option?==?'string')?data[option](_relatedTarget) ??????else?if?(options.show)?data.show(_relatedTarget)?<-?這兒就是將事件注冊(cè)到target對(duì)象上 ????}) ??}
那為什么現(xiàn)在沒(méi)有給出js腳本代碼
?...當(dāng)然是需要的 ? 這個(gè)給出的方法大概意思就是給定一個(gè)規(guī)范 ? bootstrap中的js腳本是根據(jù)data-toggle 和 data-target的值來(lái)完成交互的
舉報(bào)
告訴你使用Bootstrap,并且能夠獨(dú)立定制出適合自己的Bootstrap
1 回答使用第一種解決方法
2 回答那么問(wèn)題來(lái)了,任務(wù)需要做嗎??都不需要補(bǔ)充代碼了吧
1 回答這種引進(jìn).css文件的方法是怎么弄的?。?/p>
2 回答都是本地引入,是不是下錯(cuò)了,沒(méi)有下拉列表
2 回答在這種情況下,不知道怎么使用bootstrap
Copyright ? 2025 imooc.com All Rights Reserved | 京ICP備12003892號(hào)-11 京公網(wǎng)安備11010802030151號(hào)
購(gòu)課補(bǔ)貼聯(lián)系客服咨詢優(yōu)惠詳情
慕課網(wǎng)APP您的移動(dòng)學(xué)習(xí)伙伴
掃描二維碼關(guān)注慕課網(wǎng)微信公眾號(hào)
2015-12-25
沒(méi)腳本誰(shuí)來(lái)幫你執(zhí)行這些.... 這個(gè)肯定是要的,區(qū)別在于這里面處理了
http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.js
自己去上面這個(gè)js文件里面找modal.js,里面有這一段js
2015-09-25
那為什么現(xiàn)在沒(méi)有給出js腳本代碼
2015-09-10
?...當(dāng)然是需要的 ? 這個(gè)給出的方法大概意思就是給定一個(gè)規(guī)范 ? bootstrap中的js腳本是根據(jù)data-toggle 和 data-target的值來(lái)完成交互的