#47 tested newer better cronmail.php3

Luis M

Hello all,

I just finished checking out the latest phpslash-ft and
got surprised to see that my cronmail.php3 has been
incorporated. I got surprised also on how bad that code
was :-)
I have been using this version of the cronmail.php3
script for quite a while on latinomixed.com. It seems
to work perfectly.

- let's you use 'fortunes' to get quotes and send those
together in the regular emails (can be commented out
with no loss of functionality to the script :-) )
- better explanation on how to setup the cron job right
on top of the script.... needed for newbies and for
inclusion in the documentation
- cleaner script (cleanup a lot of odd stuff ... vim is
great ain't it?)

Bug fixes:
- Missing day got fixed. Not sure if Blake intended to
miss Tuesday, but for me that's just another regular
day. So I included Tuesday and moved the other days by
15 minutes in the schedule
- removed (commented out) the HTML part of the script
(have never used HTML newsletter format and don't think
I will; if somebody wants to test that out and add it
in a way that it can be turned off, go ahead and I will
sync mine).
- script does not continue sendmail emails if there is
no news to send! Fixed those ugly blank messages when
there is no news to send to the users... hey, some
sites are busier than others
- fixed the links sent in the message. they were
showing without the forward slash before the
"article.php3" script... thus, if you clicked on it,
nothing would happen... ugly bug! bad bug!

The attached file (tar.gz) has both a patch (.diff)
that you can apply to the actual version, and a
complete version of it (if don't feel like patching).



  • Luis M
    Luis M

    cronmail.php3 with major improvements

  • Joe Stewart
    Joe Stewart

    • status: open --> pending-accepted
  • Joe Stewart
    Joe Stewart

    Logged In: YES

    Committed with the only changes of putting the contents of
    the alter_mailinglist.sql and header.txt in the header of
    the script.

    Hope this was OK.

  • Joe Stewart
    Joe Stewart

    • status: pending-accepted --> closed-accepted
  • Joe Stewart
    Joe Stewart

    Logged In: YES

    This patch has been applied to the CVS. Please update your
    copy of PHPSlash, or wait for the next release.