Skip to content
master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 

QRjammer

QR code jammer for sharing from desktop to mobile device, or device to device ... basically so you don't have to type in the url on your phone... Special thanks to Google and Google Charts for creating the QR image generation service and URL shortener! Demo at : http://beechbot.com/demos/QRjammer

Requires:

  • jquery 1.9+

Default behavior:

  • adds a button that generates a QR code and shartened URL for the current page (whatever's in the address bar).
  • clicking the button shows the QR for scanners to jump to the URL on your device

Basic Usage:

  • include the QRjammer.js (assumes you have jQuery included first)
  • when docready or later, init via the global like this :
QRjammer.init();
  • enjoy.

Advanced Usage:

  • slam an args object in there (like this var myQR = new QRjammer.init({...}) ) to change defaults :
  • e.g. :
QRjammer.init({
	loc : 'http://google.com', // must be a full URL (default: URL)
	size : 200, // size of the QR image in pixels (default: 300)
	addCSS : false, // you can provide your own, if you like (default: true)
	addModal : false, // (default: true)
	addButton : false, // (default: true)
	addShortURL : false, // (default: true)
	buttonSize : '3em', // for the utf8 anchor icon (default: '2em')
	buttonClass : 'QRJ_fixed-top-left', // (default: 'QRJ_fixed-bottom-right')
	buttonAppendTo : $('thing') // where to put the trigger button (defaults to $(body))
});
  • built-in button classes : QRJ_fixed-top-left, QRJ_fixed-top-right, QRJ_fixed-bottom-left, QRJ_fixed-bottom-right

Methods:

  • QRjammer.getShortURL(URL); : returns a shortened url (URL is optional)
  • QRjammer.getQR(URL); : returns a QR image src (URL is optional)
  • QRjammer.show(); : opens the modal
  • QRjammer.hide(); : hides the modal

About

QR code jammer for sharing from desktop to mobile device, or device to device ...

Resources

Packages

No packages published