So the problem with your code is you are still trying to use the JSON notation for accessing the inner document when you actually need to be using the PHP notation. Since your PHP notation doesn't match anything you get the null result.
But really, this is not what you want to do as you are post processing the results in code. You could have done this server side very easily:
$result = $collection->aggregate(array(
array(
'$match' => array(
'Quote_Details.Quote_Text' => MongoRegex("/^$q/i"),
'Author_Name' => "$author"
)
),
array(
'$unwind' => '$Quote_Details'
),
array(
'$project' => array(
'_id' => 0,
'val' => '$Author_Name',
'value' => '$Quote_Details.Quote_Text'
)
)
));
echo json_encode( $result['result'], JSON_PRETTY_PRINT ) . "\n";
So now, as shown, you don't need to iterate the results anymore as you can just encode on the spot and you have re-shaped to exactly what you want in the result.