On Fri, 17 Oct 2003 15:09:48 +0100, you wrote:

>I would like to use a form in a html page to pass the variables to a php
>page, which sends an mail including these variables.
>
>All I get in the mail though is a 1 rather than the string that I put into
>the form???
>
>Can anyone help please!
>
>Some code I use....
>.
>.
>.
>$messagepart1 = '
><html> <head> <title>Free Subscription</title> </head> <body>
><p>Somebody would like to have a free subscription!!!</p> ';
>  $messagepart2 = (echo $salutation);
>  $messagepart3 = ' </body> </html> ';
>$message = $messagepart1.$messagepart2.$messagepart3;
>.
>.
>.
>mail([EMAIL PROTECTED], "Free Subscription Application", $message, $headers);

Missing quotes around the email address.

Echo the $message string as you send it, to make sure it contains what you
think it contains.

$messagepart2 = (echo $salutation);

is probably not what you meant. Try

$messagepart2 = $salutation;

instead.

What additional headers are you sending?

BTW, if the email address is coming from the outside world (your text
implies that), then your form can be used as part of a DoS attack.

>The $salutation comes from the form and is handed over correctly, but the
>syntax for to display the value of the variable in the html e-mail seems to
>be the problem...

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to