PDA

View Full Version : VBulletin Email Hack help


dfried
12-03-2003, 08:12 PM
I am running Vbulletin on a shared server. I don't have acess to the e-mail logs and my e-mail functions are not working. I have contacted my server tech people and they suguest using a differnt Php mail function than the one in Vbulletin.
When I run the test with this one from the server it works, when I run the test with the standard script it goes no where. I can not see the logs so I am stuck.
So How do we integrate the Mail::factory method into the vbmail function in
functions.php?

In vBulletin wrapper for PHP's 'mail()' function in the file functions.php,
the function vbmail uses
mail($toemail, $subject, $message, trim($headers));

our provider indicates we should code to
create the mail object using the Mail::factory method, like this:

$params['host'] = 'mail.wel-metcamps.com';
$mail_object =& Mail::factory('smtp', $params);

thanks

David

sabret00the
12-03-2003, 08:39 PM
mail($report_email, $title, $body, "From: \"$bbtitle Mailer\" <$webmasteremail>");try that, that's how i got it :)

dfried
12-03-2003, 09:21 PM
Is the PHP line you suggested suppose to replace
mail($toemail, $subject, $message, trim($headers)); ?

If not, where does it go?

Where does $report_email come from and what happens to $toemail, $subject, and $message ?

Thanks for your help!

sabret00the
12-04-2003, 07:10 AM
yep it should replace what you've got above
$report_email = $toemail = email you want to send your message too (can be renamed as long as you define it before you call it)

$title = $subject = where you wanna send the message too

$message = $body = what you want your email to say

dfried
12-04-2003, 04:50 PM
still no luck, tried all kinds of hacks , anybody have any ideas on how to include mail factory ??
Does Vbulletin use any other part of "functions php" to send e-mail ??? Could we have removed a function when I edited functions php that is needed to send e-mail ??
Or how to make this work
thanks

sabret00the
12-07-2003, 09:56 AM
sorry

mail("$report_email, $title, $body, "From: \"$bbtitle Mailer\" <$webmasteremail>");
that's the working version

dfried
12-14-2003, 03:41 PM
That fix still does not work, but I think I understand why, the current php()mail is not compatable with the anti spam features of my host server. I think I am not going to be the only one with this problem anyone with a shared server might find the same problem. My host wants to see a e-mail address that it can attach to the account that is sending out the e-mail. They are doing this so someone can't hijack the e-mail and blind spam from that account. The current vb mail sends the email from the user id, who is unknow to the host. My current hack is to send it from the host'sacount 's mail box admin ,but that is just a work around. So which one of you ace code kings can revise the php() mail so vb is happy and we are not spam hosts.