PDA

View Full Version : Script errors in function.php


beemer
04-07-2002, 04:13 AM
I am getting a script error in the functions.php file whenever a user posts to a thread that a user has asked for email notification for. Here is the line that is causing the error. What don't understand is why this just started to happen. Everything worked fine and then one day this started??

mail($touser[email],$emailsubject,$emailmsg,"From: \"$bbtitle Mailer\" <$webmasteremail>");

scsa20
04-07-2002, 04:19 AM
what's the full error??

beemer
04-07-2002, 06:18 AM
warning server error c:\inetpub\dsscrypt\forums\admin\functions.php on line 2215

Admin
04-07-2002, 10:51 AM
Try using:
mail($touser[email],$emailsubject,$emailmsg,"From: $webmasteremail");
I think that's how you fix it...

beemer
04-08-2002, 02:11 AM
Ok, I have narrowed it down a bit more. It apears that I am getting errors in every script that wants to send mail. If the script runs this command:

mail($touser[email],$emailsubject,$emailmsg,"From: \"$bbtitle Mailer\" <$webmasteremail>");

I get a script error, regardless of what script is calling the mail function. I also can not send email to any users from within the vbulletin forum. I am starting to think I might have a php problem. Has anyone had this issue before?

scsa20
04-08-2002, 05:41 AM
when you have downloaded vB, you also extrated an extral folder, in that folder there's a PHP file called mailtest.php. upload mailtest.php to your vB dir. and run it to see if your server works with it...you can also check your PHP settings by uploading phptest.php. hope this bit of info helps ;)

beemer
04-10-2002, 03:06 AM
Thanks everyone. The problem was with the SMTP gateway. I had made a change since someone used my mail server for relaying spam and it appeared to cause this problem. Once I fixed the gateway, the script errors went away.