jo-ka
Member
Hello.
I have a PHP list plugin, and I'm using the $statusMsg variable to pass messages from the code to the Success Message.
I would like to control the CSS of the message, depending the message type, for example if the code return some error, I would like to have CSS Danger like.
How can I accomplish this?
Here's part of the code...
I have a PHP list plugin, and I'm using the $statusMsg variable to pass messages from the code to the Success Message.
I would like to control the CSS of the message, depending the message type, for example if the code return some error, I would like to have CSS Danger like.
How can I accomplish this?
Here's part of the code...
PHP:
if($obj->{'Resultado'}=='OK'){
$update="UPDATE .... ";
$db->setQuery($update);
$db->query();
$contOk++;
//die($update);
$statusMsg = "Success. - Green";
}
else if($obj->{'Erros'}->{'error_1'} == 'Juiz já revalidado na época') {
$update="UPDATE .... ";
$db->setQuery($update);
$db->query();
$contNok++;
$statusMsg = "Watchout. - Yellow";
}
else {
$update="UPDATE .... ";
$db->setQuery($update);
$db->query();
$contNok++;
$statusMsg = "Danger - Error";
}
}