Re: php newbie
| From: | Rick Jansen | Date: | Sun, 17 Sep 2000 01:43:09 +0000 |
| Subject: | Re: php newbie | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-17050@lists.php.net to get a copy of this message | ||
Hi Jason,
Make a file called form.php, with this code:
<?
if (isset($mail) && isset($email)) {
mail("$email", "Internationalist Newsletter", "Hello $name,\nWe thank
you again for signing up for our newsletter \n
\nThank you once again,\nWebstaff@internationalistbooks.com");
mail("webstaff@internationalistbooks.com", "Newsletter Signup", "$name at
$email just
used the form.\n");
}
?>
<html><body>
<!-- blablabla html and layout here -->
<form action=form.php method=post>
name: <input type=text name=name>
email addr: <input type=text name=email>
<input type=submit>
<!-- blablabla more html and layout here -->
</body></html>
I think that should do the trick....
Rick Jansen
---
www.tweakers.net
www.linuxers.nl
----- Original Message -----
From: Jason <Jason@internationalistbooks.com>
To: <php-general@lists.php.net>
Sent: Sunday, September 17, 2000 3:12 AM
Subject: [PHP] php newbie
> i am trying to set up a form to let users join a mailing list and i am
> using this
> code
>
> <?
>
> mail("$email", "Internationalist Newsletter", "Hello $name,\nWe thank
> you again for signing up for our newsletter \n
> \nThank you once again,\nWebstaff@internationalistbooks.com");
>
> mail("webstaff@internationalistbooks.com", "Newsletter Signup", "$name
> at
> $email just
> used the form.\n");
>
>
> ?>
>
> how can i get this to send the emails but remain on the same page
> sorry if this is the wrong list to ask questions on
> jason
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> For additional commands, e-mail: php-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
>