require_once($_ENV['JIVENV']['funcFiles']['sendMessage']['filePath']);

$qUser = "SELECT * FROM core_users WHERE id=".$id;
$rUser = $_ENV['JIVENV']['DB'][0]->query($qUser)->fetch(PDO::FETCH_ASSOC);
$recipients[] = array(
	"Name" => $rUser['first_name'],
	"Address" => $rUser['email']
);

sendMessage(
	array(
		"id" => $id,
        "type" => "self_settings",
		"template" => "registration_email",
		"recipients" => $recipients
	)
);
