Contacts: Implemented a new QR Code generator, includes additional contact detail fields.

This commit is contained in:
Nate Jones
2014-07-26 06:02:21 +00:00
parent 67df8684e8
commit 25bc7ebc78
10 changed files with 152 additions and 1520 deletions

View File

@@ -69,8 +69,8 @@ if (count($_GET)>0) {
$vcard->data['company'] = $contact_organization;
$vcard->data['first_name'] = $contact_name_given;
$vcard->data['last_name'] = $contact_name_family;
$vcard->data['contact_email1'] = $contact_email;
$vcard->data['contact_url'] = $contact_url;
$vcard->data['email1'] = $contact_email;
$vcard->data['url'] = $contact_url;
if ($_GET['type'] == "image" || $_GET['type'] == "html") {
//don't add this to the QR code at this time
@@ -142,7 +142,12 @@ if (count($_GET)>0) {
if ($_GET['type'] == "text") {
$vcard->build();
$content = $vcard->card;
echo $content;
if ($qr_vcard) {
$qr_vcard = $content;
}
else {
echo $content;
}
}
//show the vcard in an image qr code
@@ -150,6 +155,13 @@ if (count($_GET)>0) {
$vcard->build();
$content = $vcard->card;
if (isset($_GET['debug'])) {
echo "<pre>";
print_r($vcard->data);
echo "</pre>";
exit;
}
//include
require_once PROJECT_PATH."resources/qr/qrcode.php";