嗨,我正在使用 twilio 发送和接收来自我的客户的 SMS。发送短信工作正常。
收到短信后,我想将其保存from
到Body
我的数据库中。它不起作用。这是我的代码。
控制器
function receive(){
$post_data['from'] = $this->input->post('From');
$post_data['body'] = $this->input->post('Body');
if($post_data['from'] && $post_data['body']){
$this->receive->insert_received_message($post_data);
}
}
模型
function insert_received_message($data){
$sms['pone_number'] = $data['from'];
$sms['message_type'] = 2;
$sms['body'] = $data['body'];
$results = $this->db->insert('Sms_message', $sms);
return $results;
}
我像这样将网址添加到我的号码中
已接收日志中的错误消息
有人可以帮我解决这个问题。TNX。