我是新來使用fancybox。 我加入正確的路徑的fancybox源文件,我想在這兩個Chrome和Firefox,無論控制檯返回我錯誤問題在使用Fancybox
ReferenceError: jQuery is not defined [Break On This Error]
}(window, document, jQuery));
jquery...ybox.js (line 2020) TypeError: $(...).fancybox is not a function [Break On This Error]
'type' : 'iframe'
和我的代碼是
>
$(document).ready(function() {
> $("#iframe").fancybox({
> 'width' : '75%',
> 'height' : '75%',
> 'autoScale' : false,
> 'transitionIn' : 'none',
> 'transitionOut' : 'none',
> 'type' : 'iframe' }); });
<a id="iframe" href="/cms/new.php">Submit</a>
可以在任何一個數字解決我的問題,並給我解決方案?
你確定你正在使用fancybox 2(你正在使用v1.3.4的API選項)?什麼版本的jQuery?如果你看看你的源代碼並點擊jQuery和fancybox js文件的鏈接:你能看到代碼嗎?有鏈接? – JFK