use Twilio\Twiml;
public function welcome(Request $request)
{
$twiml = new Twiml();
if(isset($request->Digits)){
switch($request->Digits){
case 1:
$twiml->say('thank you calling us');
break;
default:
$twiml->say('You have entered wrong key');
break;
}
} else{
$gather = $twiml->gather(array('numDigits' => 1));
$gather->say('Thank you for calling us. Press 1 to continue the call.');
}
return $twiml;
}
当我运行这段代码时,我收到一个错误,指出找不到类 Twlio/Twiml。更多详细信息,您可以查看错误的截图网址(https://prnt.sc/ryz1zw)。提前致谢。
拉丁的传说