D
D
dicem2017-12-20 03:18:53
JavaScript
dicem, 2017-12-20 03:18:53

Why doesn't scrolling work in PhoneGap on android?

Scrolling does not work in the PhoneGap application for Android. google,

window.addEventListener("touchstart", function(e) {    e.preventDefault();}, false);window.addEventListener("touchmove", function(e) {    e.preventDefault();}, false);

Does not help. What are you doing?

<!DOCTYPE html>
<html ng-app="growSpotDB">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=no, width=device-width">
        <title>GrowSpot Database</title>

    <!-- scripts -->
    <script>
      window.addEventListener("touchstart", function(e) {    e.preventDefault();}, false);window.addEventListener("touchmove", function(e) {    e.preventDefault();}, false);
    </script>
    <script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.5.3/angular.min.js"></script>
    <script src="src/js/jquery-3.2.1.min.js"></script>
    <script src="src/js/material.min.js"></script>
    <script src="src/js/main.js"></script>
    <script type="text/javascript" src="cordova.js"></script>

    <!-- styles -->
    <link rel="stylesheet" href="src/css/jquery.mobile-1.4.5.min.css">
    <link rel="stylesheet" href="src/css/material.min.css">
    <link rel="stylesheet" href="src/css/material-yellow.min.css">
    <link rel="stylesheet" href="src/css/material-icons.css">
    <link rel="stylesheet" href="src/css/style.css">
    <link rel="stylesheet" href="http://fonts.googleapis.com/css?family=Roboto:300,400,500,700" type="text/css">

  </head>

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
dicem, 2017-12-20
@dicem

Understood in general, Angular JS and Jquery conflicted. It's strange that it only conflicted on the phone.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question