tlenss / zabbix-sms-client

zabbix sms client script
MIT License
10 stars 10 forks source link

Error #5

Closed pablo102 closed 4 years ago

pablo102 commented 4 years ago

Hello!

After ./sms.php +37598958594 "test" "test" i got an error: PHP Warning: Constants may only evaluate to scalar values in /usr/lib/zabbix/alertscripts/config.php on line 27 PHP Notice: Use of undefined constant GATEWAY_PARAMS - assumed 'GATEWAY_PARAMS' in /usr/lib/zabbix/alertscripts/sms.php on line 16 PHP Warning: Illegal string offset 'msg' in /usr/lib/zabbix/alertscripts/lib/Zabbix/Sms/Client/Budgetsms.php on line 29 PHP Warning: Illegal string offset 'to' in /usr/lib/zabbix/alertscripts/lib/Zabbix/Sms/Client/Budgetsms.php on line 30 PHP Warning: http_build_query(): Parameter 1 expected to be Array or Object. Incorrect value given in /usr/lib/zabbix/alertscripts/lib/Zabbix/Sms/Client.php on line 108 PHP Fatal error: Call to undefined function Zabbix\Sms\curl_init() in /usr/lib/zabbix/alertscripts/lib/Zabbix/Sms/Client.php on line 67

How to solve? Debian 8 PHP 5.6.33-0+deb8u1

tlenss commented 4 years ago

This only works on a newer version of PHP. Besides that. Active support for PHP 5.6 stopped on Jan 19, 2017. It's probably best to upgrade.