[英]jquery.easing jQuery conflict
我在菜單中使用了菜單和幻燈片。 我根據菜單使用jquery.easing.1.3.js中的“ easeOutBounce”。
現在菜單工作正常。
但是它與滑塊沖突。 我不需要Slider的這種效果。 我不知道如何解決這個問題。
我不需要“ easeOutBounce”效果此URL的底部幻燈片。
當我刪除此行$.easing.def = "easeOutBounce";
時,幻燈片不是問題$.easing.def = "easeOutBounce";
從我的代碼。 但是我需要根據相應菜單的效果。
我的代碼是
<script>
$(document).ready(function(){
$.easing.def = "easeOutBounce";
$('li.button a').click(function(e){
var dropDown = $(this).parent().next();
$('li.dropdown').not(dropDown).slideUp('slow');
dropDown.slideToggle('slow');
e.preventDefault();
})
});
</script>
<script>
$(function(){
$('#slides_two').slides({
generateNextPrev: true,
pagination: false,
preload: true,
preloadImage: 'images/loading.gif',
generatePagination: false,
play: 10000,
slideSpeed: 3000,
effect: 'slide',
pause: 4000,
hoverPause: true
});
});
</script>
您可以為滑塊使用slideEasing選項。 使用此選項的代碼將是這樣:
<script type="text/javascript">
$(document).ready(function(){
$.easing.def = "easeOutBounce";
$('li.button a').click(function(e){
var dropDown = $(this).parent().next();
$('li.dropdown').not(dropDown).slideUp('slow');
dropDown.slideToggle('slow');
e.preventDefault();
})
});
</script>
<script type="text/javascript">
$(function(){
$('#slides_two').slides({
generateNextPrev: true,
pagination: false,
preload: true,
preloadImage: 'images/loading.gif',
generatePagination: false,
play: 10000,
slideSpeed: 3000,
effect: 'slide',
pause: 4000,
hoverPause: true,
slideEasing: "jswing"
});
});
</script>
緩動類型可以在這里看到。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.