我试图在PHPAGI中用户dtmf tone后从ms sql server运行存储过程,但似乎SP从未触发。任何想法或建议将非常感谢。由于
要求:
$press1 = $agi->get_data('please-select-menu',300, 1);
$press1dtmf = $press1['result'];
if ($press1dtmf=="1"){
//run ms sql stored procedure;
$agi->stream_file('thank-you');
$agi->hangup();
尝试,不工作方法:
$press1 = $agi->get_data('please-select-menu',300, 1);
$press1dtmf = $press1['result'];
if ($press1dtmf=="1"){
$sql_statement = mssql_init("sp_name '$value1' ,'$value2', '$value3'", $conn);
$result=mssql_execute($sql_statement);
mssql_free_statement($sql_statement);
$agi->stream_file('thank-you');
$agi->hangup();
}
mssql_free_result($result);
将上述内容添加到代码中,一切正常!