I am a new PhoneGap programmer. navigator.notification.alert() has not working on Android using phonegap. But it works on IPhone and WP7. I am developing this app in Windows Phone 7.
Thanks for your help
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, height=device-height, initial-scale=1.0, maximum-scale=1.0, user-scalable=no;" />
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<title>Cordova WP7</title>
<link rel="stylesheet" href="master.css" type="text/css" media="screen" title="no title"
charset="utf-8" />
<!--<script type="text/javascript" charset="utf-8" src="cordova-2.0.0.js"></script>-->
<script type="text/javascript" charset="utf-8" src="phonegap.js"></script>
<script type="text/javascript">
function doAlert() {
var message = "This is an Alert dialog";
var title = "Attention!";
navigator.notification.alert(message, title);
};
</script>
</head>
<body>
<h1>
Cordova Tests</h1>
<div id="info">
<a href="#" onclick="doAlert()">Click Me</a>
</div>
</body>
</html>
Finally, i got the solution.
Solution:
Before we build the phonegap code(in build.phonegap.com) we need to delete cordova-2.0.0.js file. If we delete this cordova-2.0.0.js, phonegap code is working on andriod.
You have to wait for
DeviceReady: