Skip to content

Instantly share code, notes, and snippets.

@FredrikAugust
Last active September 20, 2015 17:35
Show Gist options
  • Save FredrikAugust/c9db689d1dd493f14997 to your computer and use it in GitHub Desktop.
Save FredrikAugust/c9db689d1dd493f14997 to your computer and use it in GitHub Desktop.
<html>
<head>
<meta http-equiv='refresh' content='5'/>
<title>ESP8266 Demo</title>
<style>
body {
background-color: #cccccc;
font-family: Arial, Helvetica, Sans-Serif;
color: #000088;
}
</style>
<script>
function gpio () {
var xmlhttp = new XMLHttpRequest();
xmlhttp.open("GET", '/gpio');
xmlhttp.send(null);
}
</script>
</head>
<body>
<h1>Hello from ESP8266!</h1>
<p>Uptime: %02d:%02d:%02d</p>
<button onclick='gpio()'>Turn on GPIO</button>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment