title: Cordova backbutton not working
body: <p>I have a problem that Cordova event on the Back button does not do anything yet to execute alert ("").</p>
  
  <p>It is interesting that the code looks like it's perfectly fine and I did not even forget to introduce <code>cordova.js</code> the only thing I can think is that it is necessary to wash a plug-in, Because I do not have any established.</p>
  
  <p><strong>My code looks like this:</strong>
      
      </p>
  
  <pre><code>&lt;head&gt;
      &lt;meta charset="utf-8" /&gt;
      &lt;meta name="format-detection" content="telephone=no" /&gt;
      &lt;meta name="viewport" content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1, width=device-width, height=device-height" /&gt;
      &lt;link rel="stylesheet" href="css/phonon.css" /&gt;
      &lt;style&gt;
          .uvitani {
              font-size: 250%;
              margin: 0;
              color: white;
              position: absolute;
              top: 40%;
              left: 50%;
              margin-right: -50%;
              transform: translate(-50%, -50%)
          }
  
          .tlacitko {
              margin: 0;
              color: #0084e7;
              background-color: white;
              position: absolute;
              bottom: 0;
              left: 50%;
              margin-right: -50%;
              transform: translate(-50%, -50%)
          }
      &lt;/style&gt;
  &lt;/head&gt;
  &lt;script type="text/javascript" charset="utf-8"&gt;
      function barva() {
          alert(cordova.platformId);
          if (cordova.platformId == 'android') {
              StatusBar.backgroundColorByHexString("#0065b3");
          }
          document.addEventListener("backbutton", onBackKeyDown, false);
  
          function onBackKeyDown() {
              alert("Back");
          }
      }
  &lt;/script&gt;
  
  &lt;body style="background-color: #0084e7;" onload="barva();"&gt;
      &lt;center&gt;
          &lt;p class="uvitani"&gt;Vítejte v aplikaci ISAS&lt;/p&gt;
          &lt;button class="btn tlacitko" onclick='document.location="styl.html";'&gt;Pokračovat&lt;/button&gt;
      &lt;/center&gt;
      &lt;script type="text/javascript" charset="utf-8" src="cordova.js"&gt;&lt;/script&gt;
      &lt;script src="js/phonon-core.js"&gt;&lt;/script&gt;
      &lt;script src="js/components/forms.js"&gt;&lt;/script&gt;
      &lt;script src="js/components/preloaders.js"&gt;&lt;/script&gt;
      &lt;script src="js/components/dialogs.js"&gt;&lt;/script&gt;
  &lt;/body&gt;
  
  &lt;/html&gt;
  </code></pre>