Screenshot: (In device: Tap anywhere on screen, count increases) Tested and working in Android and iOS (its HTML, device independent)
Steps:
from your mobile browser. If you want the code to be hosted online and follow from step 5 below
OR If you want to have it offline without Internet, follow the steps
1. Create a new file called "simplecounter.html"
2. Open it with any text editor (notepad, etc)
3. Paste this code in it
4. Copy this html file to your mobile device<!DOCTYPE html><html>
<head>
<title>Simple Counter by Hobby Coders</title>
</head>
<body>
<center>
<br/><br/><br/>
<h1>
<div id="count">0</div></h1>
<br/><br/><br/>
<font size="1">©2012-13 HobbyCoders.com</font>
</center>
<script type="text/javascript">
var count=0;
var countPtr=document.getElementById('count');
document.addEventListener('touchstart', function(e){e.preventDefault(); count++; countPtr.innerHTML=count;}, false);
</script>
</body>
</html>
5. Open this file in Android/iOS browser. Tap anywhere on the screen to count up
If in android it doesnt work in default browser, do this
RECOMMENDED FOR ANDROID: Install this file manager app from Google Play (https://play.google.com/store/apps/details?id=com.rhmsoft.fm) and open the html file with the "HTML Viewer" of this app. It works neat and clean
6. People who dont require hi-fi app for counting, people who just need such an app for chanting or similar purposes can use this app
7. And I didnt complicate the app with save last count, reset etc because, you go back from app and open it again in browser, count resets, and press Home key, the browser goes to background and you can continue later from the same count (multitasking)
hi
ReplyDeletei new to mobile applications.i have one requirement . app like uber app.
image continuously moving when location changed.we are using our own frame work. how to develop that app by using which tech.
thanks in advance