I am running a mediawiki 1.7.1 on a PC of my company, and the email server is another pc on the intranet. I setted the mailserver address in php.ini, and enabled the mail function in mediawiki. Once I test the mail function in mediawiki I got the message like this:
"Error sending mail: mail() [function.mailhttp://192.168.21.25/ewiki/function.mail]: SMTP server response: 501 5.5.4 Invalid Address"
However, the following script in a soly php file has been tested working well.
<?php // The message $message = "Line 1\nLine 2\nLine 3";
// In case any of our lines are larger than 70 characters, we should use wordwrap() $message = wordwrap($message, 70);
// Send mail('caffinated@example.com', 'My Subject', $message); ?>
I wonder is it a bug of mediawiki? BTW, I am running mediawiki on windows xp sp2 professional chinese edition, apache 2.0.58, php 5.1.4 and mysql 5.0.22 .