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
print all session variables as email message
Moderator: General Moderators
-
djdavedawson
- Forum Newbie
- Posts: 9
- Joined: Tue Jul 29, 2008 10:13 am
Re: print all session variables as email message
Code: Select all
$submission_message = print_r($_SESSION['product']);