Neil_Bradley
asked on
php send email
I have a simple email sending script. In place of a regular message I hope to inlcude a pre formatted php file however I cant seem to get the includes script to gell with the $msg
($msg= includes 'myFile.php') does not work..
Ideas welcome.
N
($msg= includes 'myFile.php') does not work..
Ideas welcome.
N
<?php
$headers = 'MIME-Version: 1.0' . "\r\n";
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
$headers .= "Reply-To: no_reply@no_reply.co.nz \r\n";
$headers .= "From: ceo@nzpia.co.nz\r\n";
// Send
$subject = "Parachute Certificate with \"A\" Endorsement ";
$to = "neil@beaconhilldesign.co.nz" ;
$headers .= 'Cc: ' . "\r\n";
// the customers order should go here
$msg .=' I need to output my myFile.php';
mail($to, $subject, $msg, $headers);
?>
I believe that it may have to be $msg= <?php include 'myFile.php'; ?>, but the command is include without the 's'.
ASKER
That does not work as we are already in php (so don't need to use <?php ?>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
It was the only correct answer..
ASKER