Different from the other situations I found here on SO
I have the following code in the main php script
include("sql.php"); //holds all the data to mysql (and variable $db to connect)
$output = shell_exec('/usr/local/bin/php folder/another_script.php')
and in another_script.php I have this:
include_once("../sql.php"); //notice difference to previous include in the other script
$query = "some query";
$db->query($query)
$output in the first script is blank. The second script runs when alone and not called from another script. What am I missing?