c++ extension in php yii framework -
i want use c++ extension in yii. have compile .so file , used in php script. when used in yii framework, occurs "class not found",anyone knows why?
the c++ extension rdkafka.so
: https://github.com/arnaud-lb/php-rdkafka
$conf = new rdkafka\conf(); $conf->set("ssl.key.location","./conf/client.key"); $conf->set("ssl.certificate.location","./conf/client.pem"); $conf->set("ssl.ca.location","./conf/ca.pem"); $conf->set("security.protocol","ssl");
if running code in namespaced file, need either import class, or prefix \
:
$conf = new \rdkafka\conf();
Comments
Post a Comment