After asynchronous audio and video processing, the callback function always obtains the POST parameter. {Code...} although the callback failed to get the parameter, the execution was successful and the file was also processed. How can this problem be solved? After asynchronous audio and video processing, the callback function always obtains the POST parameter.
Function actionVideoProcessCallback () {/*** method provided by the official SDK. after execution, the verification fails because the parameter is null. */$ Av = new AvPretreatment ('XXX', 'XXX'); $ validation = new CallbackValidation ($ av); if ($ validation-> verifySign ()) {echo 'verification successfully';} else {echo 'verification failed';}/*** cannot be obtained directly through POST. */$ Status_code = $ _ POST ['status _ Code']; // status code of the integer processing result, 200 indicates that $ bucket_name =$ _ POST ['bucket _ name']; $ signature =$ _ POST ['signature']; $ path = $ _ POST ['path']; // save path of the array output file $ description = $ _ POST ['description']; // string processing result description $ task_id = $ _ POST ['task _ id']; // task ID corresponding to the task // Get progress // $ sugar = new AvPretreatment ('XXX', 'XXX '); // operator's account password // $ result = $ sugar-> getTasksStatus ($ task_id, 'XXX ');}
Although the callback fails to get the parameter, the execution is successful and the file is also processed.
How can this problem be solved?
Reply content:
After asynchronous audio and video processing, the callback function always obtains the POST parameter.
Function actionVideoProcessCallback () {/*** method provided by the official SDK. after execution, the verification fails because the parameter is null. */$ Av = new AvPretreatment ('XXX', 'XXX'); $ validation = new CallbackValidation ($ av); if ($ validation-> verifySign ()) {echo 'verification successfully';} else {echo 'verification failed';}/*** cannot be obtained directly through POST. */$ Status_code = $ _ POST ['status _ Code']; // status code of the integer processing result, 200 indicates that $ bucket_name =$ _ POST ['bucket _ name']; $ signature =$ _ POST ['signature']; $ path = $ _ POST ['path']; // save path of the array output file $ description = $ _ POST ['description']; // string processing result description $ task_id = $ _ POST ['task _ id']; // task ID corresponding to the task // Get progress // $ sugar = new AvPretreatment ('XXX', 'XXX '); // operator's account password // $ result = $ sugar-> getTasksStatus ($ task_id, 'XXX ');}
Although the callback fails to get the parameter, the execution is successful and the file is also processed.
How can this problem be solved?
You can read this document and directly write it into the callback. Callback notification