#!/usr/bin/env python # -*- coding:utf-8 -*- import qr f = open('spam' + qr.extension(qr.SVG), 'wb') f.write(qr.qrcode('spam, egg', format=qr.SVG, separator=0)) f.close()
#!/usr/bin/env python # -*- coding:utf-8 -*- import qr qr.qrcode("spam, egg", open("spam" + qr.extension(qr.JSON), "w"), format=qr.JSON, separator=0)
#!/usr/bin/env python # -*- coding:utf-8 -*- import qr f = open('spam' + qr.extension(qr.SVG) , 'wb') f.write(qr.qrcode('spam, egg', format = qr.SVG, separator = 0)) f.close()