473,324 Members | 1,856 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,324 software developers and data experts.

php mail bounced <full mailbox>

usafshah
104 100+
hi
i'm using php mail (running on windows 2003 server <built-in smtp> ) to send email to abc.com domain, the email is not reaching to the domain as i'm monitoring it. but as i run the script i get the following warning in browser:


Warning: mail() [function.mail]: SMTP server response: 452 4.2.2 Mailbox full in C:\Inetpub\wwwwroot\testdomain\phpmailer\index2.ph p on line 5

Message delivery failed...


here is the script that i used;

Expand|Select|Wrap|Line Numbers
  1. <?php
  2. $to = "recipient@example.com";
  3. $subject = "Hi!";
  4. $body = "Hi,\n\nHow are you?";
  5. if (mail($to, $subject, $body)) {
  6.   echo("<p>Message successfully sent!</p>");
  7.  } else {
  8.   echo("<p>Message delivery failed...</p>");
  9.  }
  10. ?>
when i try to send to gmail it works fine. but when i try to my exchange server i get the above warning but when i change the code to use auth it works fine for my exchange server
Sep 26 '07 #1
5 2595
ronverdonk
4,258 Expert 4TB
When your server is set up to use mandatory headers, you need to add e.g. the "From: xxxx@yyy\n" in the fourth parameter of the mail command.

Ronald
Sep 27 '07 #2
usafshah
104 100+
ok i have changed the code to use header (from etc)

Expand|Select|Wrap|Line Numbers
  1. <?php
  2. $headers = 'From: abc@mydomain.info' . "\r\n" .
  3.     'Reply-To: abc@mydomain.info' . "\r\n" .
  4.     'X-Mailer: PHP/' . phpversion();
  5. $to = "myid@gmail.com";
  6. $subject = "Hi!";
  7. $body = "Hi,\n\nHow are you?";
  8. if (mail($to, $subject, $body,$headers)) {
  9.   echo("<p>Message successfully sent!</p>");
  10.  } else {
  11.   echo("<p>Message delivery failed...</p>");
  12.  }
  13. ?>
  14.  



But still i can't get it, when i try on googlemail i get the message successfully.

The Quesiton is Why exchange Server isn't getting email from website (without auth)?
Sep 27 '07 #3
usafshah
104 100+
LOL sorry my fault, infact not a fault :-) but just found that If Intelligent Mail Filtering is enable in exchange server sp2 then script like this when use to send email to exchange will be blocked at connection stage. Because exchange needs a proper way to authenticate smtp before sending email


Anyway cheers ! buddy hope this thread help some one else :D
Sep 27 '07 #4
ronverdonk
4,258 Expert 4TB
Thanks for sharing your findings with us. Hope this helps somebody else.

Ronald
Sep 28 '07 #5
ak1dnar
1,584 Expert 1GB
If any of you familiar with "exchange server" Please take a look at on this thread.PHP With Exchange Server 2003
Sep 28 '07 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

6
by: The Plankmeister | last post by:
Hi... I seem to remember reading somewhere about the proper way of doing this sort of thing in the middle of some html, for example: <a href="<?= $some_url_or_other ?>">Click this!</a> What...
14
by: OldGuy | last post by:
Hi All Sendmail 8.12.11 php 4.3.9 Sendmail is installed and works properly. php is NOT in safemode from the command line; mail user@domain.com < testmsg works fine.
5
by: Eric A. Forgy | last post by:
Hello, I am just learning Java and am trying to write a method that does something like //=========================================== public Static List find(double array,double val,String...
4
by: Skip Montanaro | last post by:
(moving over from webmaster mailbox) scott> I'm sorry for bothering you, but I've tried to post to the Python scott> Tutor Mail List, tried to get someone from Bay PIggies to scott> respond, but...
0
by: Grant Edwards | last post by:
Could whoever is gatewaying this group to a mailing list PLEASE fix whatever problem is causing Usenet posters to receive bounce messages and out-of-office messages from subscribers to your...
11
by: Les Paul | last post by:
I'm trying to design an HTML page that can edit itself. In essence, it's just like a Wiki page, but my own very simple version. It's a page full of plain old HTML content, and then at the bottom,...
2
by: bissatch | last post by:
Hi, I am currently writing a simple PHP program that uses an XML file to output rows for a 'Whats New' page. Once written, I will only require updating the XML file and any pages that use the...
2
by: sf | last post by:
Hundsome Money Online Guaranteed payment month after month · Work part time or full time as you like . Make quick good cash working 2 to 3 hours a day . Work anywhere from home/ office without...
24
by: Chris F.A. Johnson | last post by:
On 2008-07-09, Denis McMahon wrote: If the left-hand column contains any text, use em rather than px to size it. In CSS, less is more. Most problems are caused by specifying too much rather...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.