Page 1 of 1

API - PHP

Posted: Wed Sep 27, 2017 8:41 pm
by Jefte
I have this command line -> /queue simple print where name~"pppoe" working fine.

But my problem is with API , trying ...

$API->write('/queue/simple/print',false);
$API->write('=where=',false);
$API->write("name~'pppoe'");

ignoring my regex '~pppoe' returning all 'queues'.

somebody have same "scenario/case" or someone suggestion?

Re: API - PHP

Posted: Thu Sep 28, 2017 1:25 pm
by boen_robot
Regular expressions are not supported by the API protocol yet.

Currently, the only way to do this sort of thing is on the PHP side, i.e. get all items, and check the properties with preg_match().

Re: API - PHP  [SOLVED]

Posted: Thu Sep 28, 2017 3:17 pm
by Jefte
I'll research about , thanks