Added ability to Enable / Disable QR LDAP

This commit is contained in:
i am da real crt yes 2022-09-07 13:21:32 +02:00
parent b26dc9d377
commit 7578a89494
1 changed files with 4 additions and 2 deletions

View File

@ -109,7 +109,7 @@
$xml .= "<Voicemail>*97</Voicemail>";
$xml .= "</Account>";
$xml .= "</AccountConfig>";
if ($_SESSION["ldap"]["qr_enable"]["numeric"] > 0){
$ldapxml = "<?xml version='1.0' encoding='utf-8'?>";
$ldapxml .= "<LdapConfig version='1'>";
$ldapxml .= "<Server>".$_SESSION["ldap"]["qr_server"]["text"]."</Server>";
@ -124,7 +124,7 @@
$ldapxml .= "<NumPro>".$_SESSION["ldap"]["qr_num_attribute"]["text"]."</NumPro>";
$ldapxml .= "<DisplayName>".$_SESSION["ldap"]["qr_display_name"]["text"]."</DisplayName>";
$ldapxml .= "</LdapConfig>";
}
// Use Default settings to set these
}
@ -205,9 +205,11 @@
if (is_uuid($extension_uuid)) {
echo "<img src=\"data:image/jpeg;base64,".base64_encode($image)."\" style='margin-top: 30px; padding: 5px; background: white; max-width: 100%;'>\n";
echo "<p>Extension QR Code</p>\n";
if ($_SESSION["ldap"]["qr_enable"]["numeric"] > 0){
echo "<img src=\"data:image/jpeg;base64,".base64_encode($ldapimage)."\" style='margin-top: 30px; padding: 5px; background: white; max-width: 100%;'>\n";
echo "<p>LDAP QR Code</p>\n";
}
}
echo "</div>\n";