function success_msg($data=array()){
$arr = $data;
}
The obtained values are as follows.
[result_code] => SUCCESS [return_code] => SUCCESS [return_msg] => OK
Please tell me how to get the data here and send it to the specified label.
For example, it is displayed like this on the page
Result code: SUCCESS
Return code: SUCCESS
Return information: OK
Thank you.
First of all, your function must have a return value to print the array inside. Add return $arr;
in the function so that you can directly var_dump(success_msg()); and you can print out the array.
The tag you are talking about refers to the html tag? To output the php code in html, write it like this <?php echo 'result code'.success_msg()['result_code'];?>
Also confirm whether your array is written correctly