Re: Errors on PHP mailforms on an Apache webserver.
| From: | William Jay | Date: | Fri, 11 May 2001 18:30:40 +0000 |
| Subject: | Re: Errors on PHP mailforms on an Apache webserver. | ||
| References: | 1 | Groups: | php.install |
| Request: | Send a blank email to php-install+get-3125@lists.php.net to get a copy of this message | ||
Change SMTP = unlockgroup.com TO: SMTP = 192.168.1.3 (ip address of smtp
server OR TO SMTP = smtp.unlockgroup.com (smtp server using name resolution)
""Admin"" <admin@unlockgroup.com> wrote in message
news:005901c051d0$2507f5e0$0200a8c0@santa...
Hello everyone,
I hope this is the right mailinglist for me. I have a problem running php
mailforms from an Apache server. Let me explain.
I have the latest Apache webserver running with PHP4.02. You can see the
specifications of the server here: Http://www.unlockgroup.com/test/index.php
As you can see the php is working (thank god finally). But I have a problem.
I made a form wich they can send to me. When they push the send button it
goes to this form:
http://www.unlockgroup.com/mailform.php , but
as you can see there is an
error on it. The strange part is that this php mailform works on another
server where php seems to be right installed. No error at all and the mail
comes at the place where it belongs. I give you the source of the
mailform.php:
<?php
$main_url="http://www.unlockgroup.com";
/*verklaar variabelen die worden gebruikt voor het aanmaken van een nieuwe
e-mail adres*/
$msg = "Sign up formulier\n";
$msg .= "\n";
$msg .= "Aanmelding voor volledige newsarchive.\n";
$msg .= "\n";
$msg .= "naam: $naam\n";
$msg .= "bedrijfs naam: $bedr_naam\n";
$msg .= "K.v.K. nummer: $kvk\n";
$msg .= "Telefoonnummer: $telefoon\n";
$msg .= "e-mail adres: $email\n";
$msg .= "\n";
$msg .= "Aangemeld door: $member\n";
$msg .= "\n";
$msg .= "Beheerde websites:\n";
$msg .= "\n";
$msg .= "$url1\n";
$msg .= "$url2\n";
$msg .= "$url3\n";
$msg .= "$url4\n";
$msg .= "$url5\n";
$msg .= "\n";
$msg .= "Leeftijd: $leeftijd\n";
$msg .= "Bank/giro nummer: $bank_giro\n";
$msg .= "Plaats: $plaats\n";
$msg .= "\n";
$msg .= "Comentaar:\n";
$msg .= "\n";
$msg .= "\n";
$ontvanger = "admin@unlockgroup.com";
$subject = "aanmelding newsarchive";
$mailheaders = "From: email <> \n";
$mailheaders .= "Reply-To: email \n\n";
/* versturen van de e-mails*/
/* Verstuur een e-mail naar admin@unlockgroup.com */
mail("$ontvanger","$subject","$msg","$mailheaders");
<=====THE CORRUPTED
LINE!!
/*print bevestiging.html*/
<END SOURCE>
So, I thought this error is coming from a corrupted line in the php.ini. The
SMTP configuration perhaps. So here I give you a part of the source of the
php.ini:
[mail function]
SMTP = unlockgroup.com ;for win32 only
sendmail_from = admin@unlockgroup.com ;for win32 only
;sendmail_path = ;for unix only, may supply arguments as well (default
is sendmail -t)
I have running a mailserver on that server wich the primary domain is
"unlockgroup.com". So, it seems to be logical to pleace "unlockgroup.com" as
the SMTP. But it doesn't work (grrr). The webserver is Mdaemon Mailserver.
What could be wrong? Is PHP sending his own SMTP? I have only one question
about this... Please, could somebody help me with this problem? I'm really
getting tired of it. My whole weekend is lost, and i have to finish it at
least monday evening. I have read all the manuals i could find on the
internet about Apache and PHP, but every time i come back at the part that i
have to setup the SMTP. And for me it looks good.
Thanks for any help you can give me about it.
Goodday,
Alex