Giter VIP home page Giter VIP logo

qrcodesvg's Introduction

qrcodesvg

http://vp-dev.net/qrcodesvg/

Create personalized Qr Code in Javascript. Qrcodesvg allow you to create beautiful QrCode on client-side.

You can apply colors and effects to your QrCode.

Qrcodesvg is based on Raphael.js a javascript library for generating vector graphic. You can grap the latest version here : http://raphaeljs.com/

Compatibility

Tested on : Firefox 13.0, Chrome 19, IE 8.

Features

Set an ecclevel for data redundancy

Apply one or many colors to squares or patterns

Add round or bevel effect to squares or patterns

Add a background and a frame.

Examples

Basic example

<!DOCTYPE html>
<html>
  <head>
		<script type="text/javascript" src="raphael-2.1.0-min.js"></script>
		<script type="text/javascript" src="qrcodesvg.js"></script>
  </head>
  <body>
  	<div id="qrcode" ></div>
  	
	<script type="text/javascript">
			//create a Qrcode in 250x250 with input 'Testing' in the HTMLElement 'qrcode'
			var qrcodesvg 	= new Qrcodesvg( "Testing Qrcodesvg", "qrcode", 250);
	
			qrcodesvg.draw();
   	</script>
  </body>
</html>

QrCode With Options

<!DOCTYPE html>
<html>
  <head>
		<script type="text/javascript" src="raphael-2.1.0-min.js"></script>
		<script type="text/javascript" src="qrcodesvg.js"></script>
  </head>
  <body>
  	<div id="qrcode" ></div>
  	
	<script type="text/javascript">
			var qrcodesvg 	= new Qrcodesvg( "Testing Qrcodesvg", "qrcode", 250, {"ecclevel" : 1});

			//add a bevel effect on patterns with a radius of 5.
			//apply one of these three colors to patterns
			qrcodesvg.draw({"method":"bevel", "radius" : 5, "fill-colors":["#1C46ED","#021872","#0125C4"]}, {"stroke-width":1});
   	</script>
  </body>
</html>

More Examples.

See mor example in test.html file.

You will see all the available options.

And don't forget to test your Qrcode !

qrcodesvg's People

Watchers

James Cloos avatar Mukesh Gupta avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.