print all session variables as email message
Posted: Tue Aug 25, 2009 3:46 pm
Im using php mail() to send an email showing form submissions.
Each of the submissions gets a session variable assigned like this:
$_SESSION['product'][0]
$_SESSION['product'][1]
$_SESSION['product'][2]
$_SESSION['product'][3]
Mail portion here:
mail($addr, $submission_subject, $submission_message)
I need to set up the message to show all the variables but I never know how many there will be.
I've tried this but it does not work:
$submission_message = print_r($_SESSION['product']);
It just goes to a white screen and then prints them on screen.
How can i get the session variables values to print as the email message?
Thanks In Advance
DD
Each of the submissions gets a session variable assigned like this:
$_SESSION['product'][0]
$_SESSION['product'][1]
$_SESSION['product'][2]
$_SESSION['product'][3]
Mail portion here:
mail($addr, $submission_subject, $submission_message)
I need to set up the message to show all the variables but I never know how many there will be.
I've tried this but it does not work:
$submission_message = print_r($_SESSION['product']);
It just goes to a white screen and then prints them on screen.
How can i get the session variables values to print as the email message?
Thanks In Advance
DD