Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create actual demo page #82

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 13 additions & 9 deletions examples/demo.html
Original file line number Diff line number Diff line change
@@ -1,23 +1,27 @@
<!DOCTYPE html>
<html>
<head>
<title>Demo page</title>

<title>Demo page</title>
</head>
<body>
<p>
TODO make a nice looking pure client qrcode generator
even allow download of the image
</p>

<p>Enter your data here and click 'generate' to create a QR Code</p>
<p>No data will be sent to a server; everything is handled in JavaScript.</p>

<form onsubmit="return refresh()">
<input type="text" id="text" value="http://jetienne.com" />
<button type="submit">Generate</button>
</form>
<div id="output"></div>

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.5.2/jquery.min.js"></script>
<script type="text/javascript" src="../jquery.qrcode.min.js"></script>
<script>
jQuery(function(){
jQuery('#output').qrcode("http://jetienne.com");
})
function refresh() {
jQuery('#output').empty().qrcode(jQuery("#text").val());
return false;
}
refresh();
</script>

</body>
Expand Down