Hi I'm trying to configure twilio with drupal voip and voip phone in particular but i get this error and as soon as I enable the module and set it as default to twilio i just get a white screen on the browser and the error log has this in it:
[warn] mod_fcgid: stderr: PHP Fatal error: Class 'Services_Twilio_Capability' not found in htdocs/sites/all/modules/voipphone/clients/voiptwilioclient/voiptwilioclient.module on line 112
anyone any idea?
I have tried to follow the instructions in both the voip phone and also the voip twilio read me's but the seem to have conflicting info. Can both these be used at the same time?
Help would be gratefully received and hopefully help others in future.
cheers
fishboy1669
Comments
Bug?
I don't use twilio but it looks to me like you might have found a bug. I can't find this class declared anywhere in the Drupal code but I did find it on github in the Twilio PHP Driver -
https://github.com/twilio/twilio-php/blob/2f3dedaec033b0af78ea5516726106...
If you don't hear from someone else here I'd create a ticket in the voipphone module.
twilio voip phone client
Hi ben,
here is the error i get again
[warn] mod_fcgid: stderr: PHP Fatal error: Class 'Services_Twilio_Capability' not found in htdocs/sites/all/modules/voipphone/clients/voiptwilioclient/voiptwilioclient.module on line 112
here is a snippit from the voiptwilioclient.module file that has line 112 in it. Im not that up on oop so its a bit above me from this point. If no one can help i'll have to get the programming book out and try understand what its trying to do.
function voiptwilioclient_get_token() {
module_load_include('php', 'voiptwilioclient', 'Services/Twilio/Capability');
$accountSid = variable_get('voipphone_twilio_account_sid', '');
$authToken = variable_get('voipphone_twilio_auth_token', '');
$appSid = variable_get('voipphone_twilio_app_sid', '');
$capability = new Services_Twilio_Capability($accountSid, $authToken); //this is line 112
$capability->allowClientOutgoing($appSid);
$token = $capability->generateToken();
return $token;
}
regards
fishboy1669
VoIP Phone module was
VoIP Phone module was accidentally published without Twilio library. You can either download the library from here: https://github.com/twilio/twilio-php/
extract it and copy Services folder to voipphone\clients\voiptwilioclient folder.
Or download the latest dev version, I just corrected this.
twillio problem
Hi tamerzg,
thanks for that the new dev version seems to work ok I am not getting the white screen lock out of drupal now so thats all good and when I use voip phone block i can dial into twilio. Guess I now just need to play with the voip scripts to change the respose from it.
One minor niggle is that the menu item has changed which may confuse people
its now
home > administer > site configuration> voip client configuration
and its heading is "voip client configuration"
it used to be "voip phone configuration"
don't know if thats a biggy or doesn't really matter in the long run besides the config name not tying in with the module name.
Thanks again for the fix.
Fishboy1669
Re: twillio problem
Both of the issues that you've reported have already been fixed and incorporated into the dev version of the module.
Best,
Leo
Cheers guys
Cheers guys