I am trying to setup an alert template that will color code the Severity and add a graph to the email. I am sending the email as html and its working well except I cant seem to get the syntax for the color codeing or adding the graph. I used the example from florianbeer at the link below
For the severity I think I’m just missing what the state should be, I cant seem to find any number that works and if I enter ‘critical’ or ‘warning’ it doesn’t work at all.
For the graph I’m just getting a place holder for a picture no actual graph, like its not finding the image so I’m not sure the path is correct. I also did enter $config[‘allow_unauth_graphs’] = 1; into my config.php.
on a side note I did read in one of the posts about using an api to get the graph instead of using $config[‘allow_unauth_graphs’] = 1;. I just couldn’t find any info on how to do that.
This is currently what I have:
Did you ever get this worked out? I am working on a similar toner page and there is some issue in the HTML that causes the entire alert to fail. I had problems with my graph in the e-mail until I went back to the config.php and corrected the single quotes… I had pasted them in and they were ` rather than ’ which happens a lot if you are pasting things in. (for the $config[‘allow_unauth_graphs’] = 1;)
Sorry I did eventually get this to work here is my Printer Notification Template. It has a table to show which toner color is low and a percentage. I also add the toner type to the printer template so it adds that. The severity will change color based off Warning or Critical, and the table also has some color and it includes the graph for each alerted toner.