Script URL:
Version of script:2.0
Hosting company:
URL of phpinfo.php:
URL of session_test.php:
What terms did you try when SEARCHING for a solution:
Write your message below:
I would like to know how to dissable all email alerts to all the registered users (the helpdesk folks) but only allow email alerts to an admin (shared Helpesk account) ? I would like to channel all email to a single email address.
How to disable email to registered users
Moderator: mkoch227
Try changig this code in submit_ticket.php and reply_ticket.php to
Didn't test it though so make a backup of old files before editing.
Code: Select all
$sql = "SELECT `email`,`isadmin`,`categories` FROM `".$hesk_settings['db_pfix']."users` WHERE `notify`='1'";
$result = hesk_dbQuery($sql);
while ($myuser=hesk_dbFetchAssoc($result))
{
/* Is this an administrator? */
if ($myuser['isadmin']) {$admins[]=$myuser['email']; continue;}
/* Not admin, is he allowed this category? */
$cat=substr($myuser['categories'], 0, -1);
$myuser['categories']=explode(',',$cat);
if (in_array($category,$myuser['categories']))
{
$admins[]=$myuser['email']; continue;
}
}
Code: Select all
$sql = "SELECT `email` FROM `".$hesk_settings['db_pfix']."users` WHERE `notify`='1' AND `isadmin`='1'";
$result = hesk_dbQuery($sql);
while ($myuser=hesk_dbFetchAssoc($result))
{
/* Is this an administrator? */
$admins[]=$myuser['email'];
}
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here 
You should follow me on Twitter here
Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...
Also browse for php hosting companies, read php books, find php resources and use webmaster tools


Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...
Also browse for php hosting companies, read php books, find php resources and use webmaster tools