I get an error when I try to use TWILIO. the error is syntax error unexpected 'use' (t_use) in php twilio.
Asked
Active
Viewed 574 times
1 Answers
0
The issue is the placement of the use statement.
//This needs to be at the top of your PHP file, not nested in a conditional eg [IF statements or while loops]: top of your PHP file like as though you are connecting to database.
require __DIR__ . '/twilio-php-master/Twilio/autoload.php';
use Twilio\Rest\Client;

Shasha
- 439
- 8
- 26