1

如何停止在 HTML5 网页中滑动和滚动?我没有为此使用任何脚本,但仍然可以滚动。如果重要的话,我正在使用 jQuery。这是我正在使用的 HTML 代码:

<!DOCTYPE HTML>  
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
        <title>BRD</title>
        <link rel="shortcut icon" type="image/ico" href="images/favicon.gif" /> 
        <link rel="apple-touch-icon" href="icon.png"/>
        <link type="text/css" href="newstyle.css" rel="stylesheet" />
        <script src="js/jquery-1.7.2.min.js"></script>
        <script src="js/jquery-ui-1.8.18.custom.min.js"></script>

        <script language="javascript" type="text/javascript">  
            function showHideDiv() { 
                document.getElementById("one").style.visibility = "visible"; 
                document.getElementById("two").style.visibility = "visible"; 

                document.getElementById("three").style.visibility = "hidden"; 
                document.getElementById("four").style.visibility = "hidden"; 

                document.getElementById("radioone").style.visibility = "visible";
                document.getElementById("radiotwo").style.visibility = "hidden";
            } 
        </script>    

        <script language"javascript" type="text/javascript">
            $(document).ready(function(){
                $(".text_paragraph").fadeIn();
            });
        </script>
4

1 回答 1

0

你是说翻页吗?下面的 JavaScript 应该做到这一点:

document.ontouchmove = function(event){
             event.preventDefault();
}
于 2012-04-25T09:58:51.913 回答