I am developing a PHP-CPP extension with c++. My extension is working perfectly when i run it through the command line. But when i try to run it in browser then the browser shows the error that class or functions not declared there. Can anyone tell me how to run it in browser?
PHP file:
<?php
include 'main.cpp';
ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);
echo "Check string";
$obj = new item();
echo "string";
$obj->DBconnect();
echo "string";
?>
Please see the picture Picture will provide the better idea