A
A
Artyom2021-04-03 14:20:11
PHP
Artyom, 2021-04-03 14:20:11

Access denied. How do you know what a variable is passing?

When sending a test message, it gives the error "+3712995****: {"error":"access denied"}" . API key entered correctly.
How can I find out what the sms_service_id variable sends?
The code:

return file_get_contents_curl("https://app.sms.by/api/v1/sendQuickSMS?token=".$settings["sms_service_id"]."&message=".urlencode($text)."&phone=".$phone_to);


Function:
unction sms($phone_to="",$text=""){
   global $settings, $config;

   if($settings["sms_service_pass"]){
      $settings["sms_service_pass"] = decrypt($settings["sms_service_pass"]);
   }

   if($settings["sms_service_id"]){
      $settings["sms_service_id"] = decrypt($settings["sms_service_id"]);
   }


The form itself says:
value="<?php echo decrypt($settings["sms_service_id"]);

and the correct API is displayed there.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question