-
-
Save kevinbond/844762b2f57364f0bff0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$recorded = false; | |
function callConnected($event) { | |
global $recorded; | |
$recorded = true; | |
_log("************** starting the recording"); | |
startCallRecording("ftp://username:password@ftp.tropo.com/recordings/connectedRecording.mp3"); | |
} | |
transfer("+14071234321", array( | |
"playvalue" => "http://www.phono.com/audio/holdmusic.mp3", | |
"terminator" => "#", | |
"timeout" => 40.0, | |
"onConnect" => "callConnected" | |
)); | |
if($recorded){ | |
_log("************** killing the recording"); | |
stopCallRecording(); | |
say("ftp://username:password@ftp.tropo.com/recordings/connectedRecording.mp3"); | |
} | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment