When you add a recordset to an email body you have to use require() instead of require_once() for adding the connection. So this on hadith-email.php:
<?php require_once('../../Connections/hadithbd.php'); ?>
should be this:
<?php require('../../Connections/hadithbd.php'); ?>
Or you could just carry it over as a global variable like:
<?php
global $hadithbd;
?>