Advertisement:

Author Topic: [SOLVED] Make Premium Email Notification - Do Not Send...  (Read 885 times)

richieboymx

  • Full Member
  • ***
  • Posts: 110
[SOLVED] Make Premium Email Notification - Do Not Send...
« on: February 24, 2015, 09:08:24 pm »
Hello community,

As the title says, is it possible to deactivate the email sent to invite the user to make his ad premium when a new ad is posted by the administrator or moderator?

This would be the ideal scenario, but if also anyone knows how to prevent this notification to be sent at any new posted ad, that would be helpful as well.

Thanks,
« Last Edit: February 26, 2015, 04:07:14 pm by ramutio »

teseo

  • Hero Member
  • *****
  • Posts: 6169
Hi,

Yes, just add this at the very bottom of your theme functions.php (take care not to leave blank lines after this):

Code: [Select]
<?php if (osc_is_admin_user_logged_in()) Preference::newInstance()->set('allow_premium'0'payment'); ?>
Regards

richieboymx

  • Full Member
  • ***
  • Posts: 110
@teseo

Thank you for the fix!

Quote
Oh, sorry I read your first message hastily. You'll need to alter the plugin code a bit, replace this line in ppaypal/index.php:

Code: [Select]
payment_send_email($item, $category_fee);

with

Code: [Select]
if (!osc_is_admin_user_logged_in()) payment_send_email($item, $category_fee);

if you want no mail only for admin, or comment it to avoid sending any email at all.