Drupal set message class I've been trying to add a class to a drupal_set_message() function. i found one article that said it worked, but i could not get it to work on mine. am i missing something?

I have drupal_set_message(t('an error has occured'),'custom-error');

these are the only output i get from the html

&lt;div class="alert alert-block"&gt;
&lt;a class="close" data-dismiss="alert" href="#"&gt;×&lt;/a&gt;
an error has occured&lt;/div&gt;


any help would be appreciated.
For drupal set message below is a syntax.

drupal_set_message($message = NULL, $type = 'status', $repeat = TRUE);


Parameters

string $message: (optional) The translated message to be displayed to the user. For consistency with other messages, it should begin with a capital letter and end with a period.

string $type: (optional) The message's type. Defaults to 'status'. These values are supported:

'status'

'warning'

'error'

You should pass any one of the status message with your custom class separated with space as shown below

drupal_set_message(t('an error has occured'),' status custom-error');