SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Enthusiast Almasty's Avatar
    Join Date
    Mar 2009
    Posts
    28
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question mail() and Sendmail - additional_parameters & send delay

    Hi

    Does anyone know if when using the mail() function PHP 4.x for the `additional_parameters` argument can any additional paremeter be passed that will delay the mail being sent until a specific server time or indeed by a specific delay time e.g. 1 minute.

    The hosting platform is configured to use Sendmail so this might as well be as much about whether Sendmail offers that function or not.

    Any help greatly appreciated.

    P.S. I wish I had root access to the host environment to store the e-mails I want to send in a db, then have a cron job check on whether they should be sent via a timestamp but I don't have that access. Plus I really, really do not want to use sleep() anywhere. Trying to be creative and figure an answer out to this issue with what I have got access to.

  2. #2
    Follow Me On Twitter: @djg gold trophysilver trophybronze trophy Dan Grossman's Avatar
    Join Date
    Aug 2000
    Location
    Philadephia, PA
    Posts
    20,580
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Almasty View Post
    P.S. I wish I had root access to the host environment to store the e-mails I want to send in a db, then have a cron job check on whether they should be sent via a timestamp but I don't have that access.
    Many shared hosts enable cron job creation in cPanel, so you wouldn't need root access or even shell access at all.

  3. #3
    SitePoint Enthusiast Almasty's Avatar
    Join Date
    Mar 2009
    Posts
    28
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I think it is going to be something like:

    Code:
    MinQueueAge=timeout
    From the Sendmail manual. There are some other options though e.g.

    Code:
    -qp[time]
    Before I get into the implementation, are there any Sendmail guru's that have a advice preference?

    P.S., Thanks for the feedback Dan!


Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •