问题
I am having a problem "Muting" an outgoing call through Twilio Client. I am able to mute calls when I receive an incoming call, however, when I make an outgoing call, the mute button does not work. I have tried everything I can think of to make this mute button work but nothing I do works. Here is a link with the code:
<script type="text/javascript">
function call() {
//Get the phone number to connect the call to
params = {"PhoneNumber": $("#number").val()};
Twilio.Device.connect(params);
$("#mute").click(function() {
conn.mute();
});
}
</script>
<button id="mute">
Mute
</button>
Please help with this. It has been driving me crazy. I cannot figure this out! Thanks
回答1:
Shouldn't you be setting conn = Twilio.Device.connect(params);?
https://www.twilio.com/docs/api/client/device#connect
来源:https://stackoverflow.com/questions/11300530/twilio-client-mute-button-not-working