0

JS初学者在这里。我一直在尝试在我的网站上制作slabtext,但出现错误。不知道如何解决它。

$(window).load(function() {
Uncaught TypeError: Property '$' of object [object Object] is not a function
    slabTextHeadlines();
});


// Function to slabtext the hero panel
function slabTextHeadlines() {
    $('html:not(.ie8)').find('.slab').slabText({
        // Don't slabtext the headers if the viewport is under 380px
        "viewportBreakpoint":380
    });
};

有任何想法吗?巴勃罗。

4

2 回答 2

0

Try this :

<script type="text/javascript" src="http://code.jquery.com/jquery-1.9.1.min.js" > </script>
$(window).load(function() {
    slabTextHeadlines();
});


// Function to slabtext the hero panel
function slabTextHeadlines() {
    $('html:not(.ie8)').find('.slab').slabText({
        // Don't slabtext the headers if the viewport is under 380px
        "viewportBreakpoint":380
    });
};
于 2013-03-09T00:35:02.737 回答
0

你库 jquery 插件了吗?像 jquery.min 吗?

<script type="text/javascript" src="js/jquery.min" />
<script type="text/javascript" src="js/jquery-ui-1.8.22.custom.min" />
于 2013-03-09T00:25:45.867 回答