Show QR Codes in Web Pages

user-pic
Vote 0 Votes

使用 Google APIs 可以很輕易地把 QR Code 顯示在網頁上, 不用自已寫程式, 中文也沒問題

Getting Started with Infographics
https://chart.googleapis.com/chart?chs=150x150&cht=qr&chl=Hello%20world
參數:
chs - QR Code 大小, 格式 寬x高
cht - 類型, 'qr' 表示 QR code, 固定參數
chl - 要編碼的資料, 必需是 URL-encoded.

chs 最小是 30x30 左右, 因資料量而異

因為有 300000 pixels 上限, chs 最大是 547x547

除了 GET 方式之外, 也可以用 POST 的方式, 因為 URL 長度有 2K 的限制, 用 POST 則無,
可參考 POST Requests

Leave a comment

About this Entry

This page contains a single entry by Pank published on February 17, 2012 12:28 AM.

Install DropBox for Linux was the previous entry in this blog.

Fix PHP mysql_connect() Headers and client library minor version mismatch is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.

Monthly Archives