Skip to content

Instantly share code, notes, and snippets.

@ricardoreis
Created October 1, 2018 00:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ricardoreis/44e21795fab94d24fb629f8020028d29 to your computer and use it in GitHub Desktop.
Save ricardoreis/44e21795fab94d24fb629f8020028d29 to your computer and use it in GitHub Desktop.
<html>
<head>
<script src="https://js.pusher.com/4.3/pusher.min.js"></script>
<script>
// Enable pusher logging - don't include this in production
Pusher.logToConsole = true;
var pusher = new Pusher('18d514638e535062bd73', {
cluster: 'us2',
forceTLS: true
});
var channel = pusher.subscribe('my-channel');
channel.bind('my-event', function(data) {
window.location = "payment_received.html";
//alert(JSON.stringify(data));
});
</script>
</head>
<body style="margin:0px; padding:0px">
<img onclick="window.location = 'payment_received.html';" src="qr.png" />
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment