</div> <center><h2>WiFi clear-guest password QRCode</h2></center> <center> <?php include "qrcode.php"; $qr = new qrcode(); //bookmark $title = "antdz"; $url = "https://webauth-redirect.oracle.com/login.html?"; $password = trim(shell_exec('cat pass')); $param = "username=guest&password="******"&buttonClicked=4"; $url = $url . $param; $qr->bookmark($title, $url); //.......URL echo "<img src='" . $qr->get_link() . "'>"; //here is the way to output image //header("Content-type:image/png"); //echo $qr->get_image(); //and here is the way to force image download //$file = $qr->get_image(); //$qr->download_image($file) ?> </center> <br/> <center><?php echo shell_exec('cat pass'); ?>
//then we check what type of information user wanted to create qr code //to know what are possible types and what information needs to inserted, check the example file switch ($_POST['type']) { case "url": //then we use submitted information here, word inside $_POST[] brackets must match value of name attribute in the input field //<p>http://<input type='text' name='url' $qr->link($_POST['url']); break; case "txt": $qr->text($_POST['txt']); break; case "sms": $qr->sms($_POST['sms_phone'], $_POST["sms_text"]); break; case "bookmark": $qr->bookmark($_POST['mms_phone'], $_POST["mms_text"]); break; case "tel": $qr->phone_number($_POST['tel']); break; case "contactinfo": $qr->contact_info($_POST["contact_name"], $_POST["contact_address"], $_POST["contact_phone"], $_POST["contact_email"]); break; case "email": $qr->email($_POST["email_address"], $_POST["email_subject"], $_POST["email_txt"]); break; case "geo": $qr->geo($_POST["geo_lat"], $_POST["geo_lon"], $_POST["geo_above"]); break; case "wifi": $qr->wifi($_POST["wifi_aut"], $_POST["wifi_ssid"], $_POST["wifi_pass"]);
* Here are sources with free QR code reading software for mobile phones: * http://reader.kaywa.com/ * http://www.quickmark.com.tw/En/basic/download.asp * http://code.google.com/p/zxing/ * * For more information, examples and online documentation visit: * http://webcodingeasy.com/PHP-classes/QR-code-generator-class **************************************************************/ include "qrcode.php"; $qr = new qrcode(); //link $qr->link("http://code-snippets.co.cc"); echo "<p>Link</p>"; echo "<p><img src='" . $qr->get_link() . "' border='0'/></p>"; //bookmark $qr->bookmark("WebcodingEasy.com", "http://webcodingeasy.com"); echo "<p>Bookmark</p>"; echo "<p><img src='" . $qr->get_link() . "' border='0'/></p>"; //text $qr->text("Any UTF8 characters like �ēū"); echo "<p>UTF8 text</p>"; echo "<p><img src='" . $qr->get_link() . "' border='0'/></p>"; //sms //First parameter - phone number //Second parameter - sms text $qr->sms("12345678", "sms text"); echo "<p>SMS with phone number and text</p>"; echo "<p><img src='" . $qr->get_link() . "' border='0'/></p>"; //phone number $qr->phone_number("12345678"); echo "<p>Telephone number</p>";