| <?php |
| |
| $serves= $_GET['serves']; |
| $did = $_GET['did']; |
| $password = $_GET['password']; |
| $path = $_GET['path']; |
| $path1 = $_GET['path1']; |
| |
| |
| |
| if ($serves== NULL) { |
| print "read=t-אנא בחרו את שרת המערכת שברצונכם להגדיר, למערכת בשרת הרגיל הקישו אחד, להגדרת מערכת בשרת הפרייוט הקישו שתים=serves,yes,1,1,7,No,yes,yes,*/,1.2,,,,"; |
| exit; |
| } |
| if ($did == NULL) { |
| print "read=t-אנא הקישו את מספר המערכת שברצונכם להגדיר=did,yes,10,9,15,Digits,yes,,,,,,,"; |
| exit; |
| } |
| if ($password == NULL) { |
| print "read=t-אנא הקישו את סיסמת הניהול של המערכת שברצונכם להגדיר=password,yes,100,1,24,Digits,,,,,,,,"; |
| exit; |
| } |
| if ($path== NULL) { |
| print "read=t-אנא הקישו את מספר השלוחה וסולמית בסיום=path,no,10000,0,14,Digits,no,no,*/,,,ok,,"; |
| exit; |
| } |
| if ($path1== NULL) { |
| print "read=t-אנא הקישו את מספר השלוחה החדשה וסולמית בסיום=path1,no,10000,0,14,Digits,no,no,*/,,,ok,,"; |
| exit; |
| } |
| if ($serves== 1) { |
| $url = json_decode(file_get_contents("https://www.call2all.co.il/ym/api/FileAction?token=$did:$password&action=copy&what=ivr2:$path/ext.ini&target=ivr2:$path1/ext.ini"), true); |
| $status = $url['boolean']; |
| if ($status == "true") { |
| print "id_list_message=t-ההגדרה עודקנה בהצלחה בשלוחה .d-$path1.t-משלוחה.d-$path&"; |
| |
| } else { |
| print "id_list_message=t-חלה שגיאה בהגדרת המערכת, יתכן שהמספר מערכת או הסיסמא שגויים, או שהשרת נחסם מימות המשיח עד לשלושים דקות הבאות &"; |
| } |
| |
| |
| exit; |
| } |
| |
| if ($serves== 2) { |
| $url = json_decode(file_get_contents("https://private.call2all.co.il/ym/api/FileAction?token=$did:$password&action=copy&what=ivr2:$path/ext.ini&target=ivr2:$path1/ext.ini"), true); |
| $status = $url['boolean']; |
| if ($status == "true") { |
| print "id_list_message=t-ההגדרה עודקנה בהצלחה בשלוחה .d-$path1.t-משלוחה.d-$path&"; |
| |
| } else { |
| print "id_list_message=t-חלה שגיאה בהגדרת המערכת, יתכן שהמספר מערכת או הסיסמא שגויים, או שהשרת נחסם מימות המשיח עד לשלושים דקות הבאות &"; |
| } |
| |
| |
| exit; |
| } |
| |
| ?> |