I've got an HTML file I use as a template for a PHP email, and I want to just pull the contents of the HTML file and put it in a string, but my PHP content isn't showing.
My current html file can be seen at http://pastebin.com/iNgaHRky
I can get the file to be pulled, but the PHP parts in it aren't running. The email is just coming through as if I was previewing the file itself.
My Code:
ob_start();
include(site_url()."/emails/templates/new_user_admin.html");
$adminMessage = ob_get_clean();
ob_end_clean();
Can anyone let me know if what I'm trying to do is possible, and any way to get this to work?
I've also tried file_get_contents()
.phpand use include like the rest of us?