8 ביוני 2021, 17:13

@יוסף-ח

<?php
$ApiDID = $_GET['DID'];
$password = $_GET['pass'];
$TxtLoginApidid = "אנא הקישו את מספר המערכת, ולסיום הקישו סולמית!";
$TxtLoginPasspord = "אנא הקישו את סיסמת הניהול, ולסיום הקישו סולמית!";
$TxtLoginPasspordWarning = "שימו לב, אם אינכם בטוחים שהנכם יודעים את הסיסמא, אנא נתקו את השיחה ובדקו זאת על ידי חיוג למערכת הטלפונית";
$FolderLoginOk = $_GET['FolderLoginOk'];
$FolderLoginError = $_GET['FolderLoginError'];
if ($_GET['DID'] == NULL){
    echo "read=t-$TxtLoginApidid=DID,yes,10,9,10,No,yes";exit();}
if ($_GET['pass'] == NULL){
    echo "read=t-$TxtLoginPasspord $TxtLoginPasspordWarning! $TxtLoginPasspord=pass,yes,,,10,No,yes";exit();}
$str = file_get_contents("https://www.call2all.co.il/ym/api/https://www.call2all.co.il/ym/api/Login?username=$ApiDID&password=$password");
$str = json_decode($str,true);
if ($str["responseStatus"] === "OK"){
     echo "id_list_message=t-ההתחברות בוצעה בהצלחה, למערכת מספר.d-$ApiDID.&go_to_folder=$FolderLoginOk";}
else{
     echo "id_list_message=t-שגיאה! אחד או יותר מהנתונים שהוקשו שגויים! שלום ותודה!&go_to_folder=hangup&";
}
?>