• Resolved yezzz

    (@yezzz)


    In the DB I see various cards that have a future_send date/time in the past with no card_sent date.

    So I tested sending a card in the past, or even using “today” (ie. always a minute or so in the past). Card will submit without advising the user it’s a past date/time, but the ecard never gets send. Please make it more foolproof (as apparently there’s many of ’em) or add some code that checks overdue ecards and trigger sending them.

    https://www.ads-software.com/plugins/wp-greet/

Viewing 15 replies - 16 through 30 (of 30 total)
  • Thread Starter yezzz

    (@yezzz)

    I should add that I do really appreciate your efforts!

    Thread Starter yezzz

    (@yezzz)

    Went through your code and it looks like the changed cronjob values is part of the update? (using mid and not using fetchcode).

    Another look at the db and I see the card_sent values stay at 0000-00-00 00:00:00

    Plugin Author tuxlog

    (@tuxlog)

    Can you give detail on one entry in wpgreet_cards which is not working, seems to work here

    I tested:

    entries which were not sent in the past and
    entries which loosed their cron entry

    works here

    Thread Starter yezzz

    (@yezzz)

    Here’s one (I edited some values yesterday while testing):

    mid: 66
    …..
    cc2from: 0
    …..
    confirmuntil: 2014-12-27 00:20:22
    confirmcode: (empty)
    fetchuntil: 2015-03-27 00:10:50
    fetchcode: wpgreet_549deafabf663
    card_sent: 0000-00-00 00:00:00
    card_fetched: 0000-00-00 00:00:00
    future_send: 2014-12-26 23:21:00
    session_id: v8iito5on0807tr03fhlmng9q7

    After using the rescheduler and refreshing the cron events page I see several cron events. The one matching above ecard:
    (edited names and email addresses, they were valid ones)
    Hookname: wpgreet_sendcard_link
    Arguments: [“66″,”[email protected]”,”from name”,”[email protected]”,”to name”,”90″,null,false]
    Next Run: 2014-12-26 01:00:00 (now)

    After refreshing page again all cron events are gone. I did also visit a front end page.

    No changes and no mail sent. No cron -anything in wp-config.
    Wp greet settings: using smtp, static sender and mailreturnpath are same email as smtp username. Fetch card online. No minimum user role, no spam protection.

    Thread Starter yezzz

    (@yezzz)

    ok, I realize I never tested future send on my local install, which is where I’m testing the reschedule. So I tested future send and not working. So the issue could be cronjob not doing anything? How do I troubleshoot that?

    Thread Starter yezzz

    (@yezzz)

    Apperently xampp doesn’t include any functionality to support cronjobs. My guess is wp-cron also needs such functionality, even though it’s triggered by loading a page.

    So I’m gonna test it on the live server. I hope v4.7 is stable. Here goes nothing….

    Thread Starter yezzz

    (@yezzz)

    Tested 4.7 on the live server, but did not seem to be working. Did not reactivate plugin so maybe my test wasn’t done properly. Also, I was reusing a sent card which may cause trouble?? (there’s also an issue with clearing the form after preview, there may well be a similar issue with reading/posting form values?)

    Anyway, I went back to v4.6 and found another problem with that version: when using future send and tick “copy to sender” the system does not send the copy to sender.

    Thread Starter yezzz

    (@yezzz)

    To be clear:

    v4.7: I only tested the emailing function, not the reschedule function. There’s no point in testing that if the email function doesn’t work. I assume you only tested the rescheduler?

    v4.6: with future send: recipient receives card, webmaster receives copy of the card, sender receives read confirmation. The only thing that fails is copy to sender. There’s no CC.

    Please feel free to test it on https://reisfavoriet.nl/ecard

    Thread Starter yezzz

    (@yezzz)

    btw, shouldn’t the rescheduler also use card_fetched = 0000-00-00 00:00:00 as card_fetched with a date it’s likely they have received the card.

    Plugin Author tuxlog

    (@tuxlog)

    v4.6: with future send: recipient receives card, webmaster receives copy of the card, sender receives read confirmation. The only thing that fails is copy to sender. There’s no CC.

    just tested this with v4.7. and it seems to work here in test and live

    we should only test again one version since it is to confusing otherwise.

    Plugin Author tuxlog

    (@tuxlog)

    v4.7: I only tested the emailing function, not the reschedule function. There’s no point in testing that if the email function doesn’t work. I assume you only tested the rescheduler?

    mails work here too. rescheduler works too. It just found five test cards about a year old in my database and sent the mails correctly

    maybe it is a special configuration which causes this. can you give your setup please or send it by mail as a screenshot if it is easier for you.

    Thread Starter yezzz

    (@yezzz)

    Agreed, let’s test v4.6. Properly working future send has priority over rescheduler. I’m sending you screenshots.

    Thread Starter yezzz

    (@yezzz)

    Happy new year!

    Did you receive the screenshots?

    Thread Starter yezzz

    (@yezzz)

    Also, are you sure you included the correct files in v4.6?

    For instance, in wp-greet.php I see this code

    // wrapper functions for wp_cron trigger
    function cron_sendGreetCardMail($sender,$sendername,$recv,$recvname,$title,
    				$msgtext,$picurl,$ccsender,$debug=false)
    { echo "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa";
      sendGreetcardMail($sender,$sendername,$recv,$recvname,$title,$msgtext,$picurl,$ccsender,$debug);
      log_greetcard($recv,addslashes($sender),$picurl,$msgtext);
    }
    
    function cron_sendGreetCardLink($sender,$sendername,$recv, $recvname,$duration, $fetchcode, $debug=false)
    {
      sendGreetcardLink($sender,$sendername,$recv, $recvname,$duration, $fetchcode, $debug);
      mark_sentcard($fetchcode);
    }

    I’m using the ecard as a link, and I don’t see $ccsender in there. You sure this is correct? (and what’s the “aaaaaaaaa” echo doing there btw?)

    Or perhaps the cc is sent immediately and handled somewhere else in the code?

    Plugin Author tuxlog

    (@tuxlog)

    Okay, hope I finally got it. At least it works now in my installations.
    Please check v4.7. (to be released soon)

Viewing 15 replies - 16 through 30 (of 30 total)
  • The topic ‘Future cards – again’ is closed to new replies.