Mail() sender's address?

All support enquiries for DFH go in here...

Mail() sender's address?

Postby test » Fri Nov 04, 2011 11:48 pm

Where, or how can I set the e-mails sent from DFH to the users (like when they fill in their e-mail and hit the upload file)?
I want to make it that when the user fill in his e-mail, and the script sends him his upload details (download link & delete link), on the mail he'll get, the sender address will be address I've set, let's say mailer@myfilehost.com, for example, so the user will know that it's from my site without even opening it first.

Hope you understand me.

Thanks! :)
test
Standard Member
 
Posts: 37
Joined: Tue Apr 05, 2011 1:21 pm

Re: Mail() sender's address?

Postby SamEA » Mon Nov 07, 2011 2:37 pm

This line
Code: Select all
headers = 'From: noreply@' .$emailsender . "\r\n" .
found in ./pages/register.php and ./pages/login.php

But the user should already know it's coming from your site, because $emailsender holds your domain address.
SamEA,
DaddyScripts' Admin & Developer.

Require a PHP or general IT freelancer? Don't hesitate to PM me.
User avatar
SamEA
Site Admin
 
Posts: 1165
Joined: Sat Feb 19, 2011 7:51 pm

Re: Mail() sender's address?

Postby test » Mon Nov 07, 2011 4:10 pm

Well, this is good news to me, since my DFH installation is sending the mail through a shared server, so the address is not like my domain. I think you should set a global "Sender E-mail address", to allow more customization on mails getting sent from the DFH installation.

The file you mentioned will help me at the moment until, and if the feature I've suggested will be implemented.

But, there's one more place I need to alter my DFH installation sender address... It's in ./upload.php, in the variable:
$uploadmsg

How can I alter the headers of the mail being sent within the $uploadmsg variable? Thanks for your help.
test
Standard Member
 
Posts: 37
Joined: Tue Apr 05, 2011 1:21 pm

Re: Mail() sender's address?

Postby SamEA » Tue Nov 08, 2011 3:09 am

I never tested DFH through a shared server and that is why such an idea was never thought of. I will take that feature into consideration for future versions.

Find
Code: Select all
mail($_POST['myemail'],"Your Uploaded File",$uploadmsg,"From: ". $email ."\n");
in ./upload.php and change to
Code: Select all
mail($_POST['myemail'],"Your Uploaded File",$uploadmsg,"From: donotreply@yourdomain.com\n");


Realize I removed the $email variable and replaced it with donotreply@yourdomain.com
SamEA,
DaddyScripts' Admin & Developer.

Require a PHP or general IT freelancer? Don't hesitate to PM me.
User avatar
SamEA
Site Admin
 
Posts: 1165
Joined: Sat Feb 19, 2011 7:51 pm

Re: Mail() sender's address?

Postby test » Tue Nov 08, 2011 10:01 am

Great! Just what I've needed! And also this will be a good feature, atleast for people like me.

Thanks alot! Keep up the good work! :)
test
Standard Member
 
Posts: 37
Joined: Tue Apr 05, 2011 1:21 pm

Re: Mail() sender's address?

Postby SamEA » Tue Nov 08, 2011 11:02 am

Glad you're enjoying DFH :).
SamEA,
DaddyScripts' Admin & Developer.

Require a PHP or general IT freelancer? Don't hesitate to PM me.
User avatar
SamEA
Site Admin
 
Posts: 1165
Joined: Sat Feb 19, 2011 7:51 pm


Return to Daddy's File Host v1.X

Who is online

Users browsing this forum: No registered users and 5 guests

cron