
05-12-2013, 04:39 PM
|
|
|
Join Date: Dec 2003
Location: SoCal
Posts: 3,954
Благодарил(а): 0 раз(а)
Поблагодарили:
0 раз(а) в 0 сообщениях
|
|
Quote:
Originally Posted by Drareg
I thought so. We do not use PayPal or anything else, just members pay per bank. But when the member gets an expire email, it would just be nice that the Admin also gets a notification of this. I could not find anything so far about this, suggestions?
Maybe it's simpel by coding the subscriptions.php in includes/cron and add the Admins email address, but I'm not a coder unfortunatly.
PHP Code:
vbmail_start(); while ($subscriptions_reminder = $vbulletin->db->fetch_array($subscriptions_reminders)) { require_once(DIR . '/includes/functions_misc.php'); $subscription_title = fetch_phrase('sub' . $subscriptions_reminder['subscriptionid'] . '_title', 'subscription', '', true, true, $subscriptions_reminder['languageid']);
$username = unhtmlspecialchars($subscriptions_reminder['username']); eval(fetch_email_phrases('paidsubscription_reminder', $subscriptions_reminder['languageid'])); vbmail($subscriptions_reminder['email'], $subject, $message); } vbmail_end();
Something else, below in subscriptions.php is this line:
PHP Code:
// time for the reminders $subscriptions_reminders = $vbulletin->db->query_read(" SELECT subscriptionlog.subscriptionid, subscriptionlog.userid, subscriptionlog.expirydate, user.username, user.email, user.languageid FROM " . TABLE_PREFIX . "subscriptionlog AS subscriptionlog LEFT JOIN " . TABLE_PREFIX . "user AS user ON (user.userid = subscriptionlog.userid) WHERE subscriptionlog.expirydate >= " . (TIMENOW + (86400 * 2)) . " AND subscriptionlog.expirydate <= " . (TIMENOW + (86400 * 3)) . " AND status = 1 ");
Can I change TIMENOW + (86400 * 2) and TIMENOW + (86400 * 3) to longer periods without problems? For example TIMENOW + (86400 * 7) and TIMENOW + (86400 * 14)
Thanks.
|
You'll need to write a script to query the susbcriptions, generate an email and save it as a cron. Questions on coding like that are far better directed to the coding forum here where you get access to all sorts of individuals rather than a support thread like this one which is visited by very few developers.
|