[% SET message = get_message(c) %]
[% IF message %]
<div id="thruk_message" class="thruk_message" style="position: fixed; z-index: 5000; width: 600px; top: 30px; left: 50%; margin-left:-300px;">
  <div class="shadow"><div class="shadowcontent">
  <table cellspacing=2 cellpadding=0 width="100%" style="background: #F0F1EE; border: 1px solid black">
    <tr>
      [% IF message.2 %]
      <td width="50" align="left" valign="top">
        <a href="#" onclick="toggleElement('message_details', 'message_details_icon');return false;"><img src="[% url_prefix %]thruk/themes/[% theme %]/images/icon_maximize.gif" id="message_details_icon" alt="show details" width="13" height="12" class="close_button" style="margin-left: 4px;"></a>
      </td>
      [% END %]
      <td align="center">
        <span class="[% message.0 %]">[% message.1 %]</span>
        [% IF message.0 == 'fail_message' %]
          <img src='[% url_prefix %]thruk/themes/[% theme %]/images/error.png' alt='Errors detected' title='Errors detected' width="16" height="16" style="vertical-align: text-bottom">
        [% END %]
      </td>
      <td valign="top" align="right" width="50">
        <a href="#" onclick="jQuery('#thruk_message').hide('fade', {}, 500);return false;"><img src='[% url_prefix %]thruk/themes/[% theme %]/images/icon_close.gif' border="0" alt='Hide Message' title='Hide Message' width="13" height="12" class="close_button" style="margin-right: 4px;"></a>
      </td>
    </tr>
    [% IF message.2 %]
    <tr style="display:none" id="message_details">
      <td colspan=3 align="center">
        <div style="float: left; position: relative; left: 50%;">
        <pre class="[% message.0 %]" style="float: left; position: relative; left: -50%; text-align: left;">
          [% FOREACH detail = thruk_message_details %]
          [% detail %]<br>
          [% END %]
        </pre>
        </div>
      </td>
    </tr>
    [% END %]
  </table>
  </div></div>

  [% IF message.0 == 'success_message' %]
  <script type="text/javascript">
  <!--
  window.setTimeout("jQuery('#thruk_message').hide('fade', {}, 500)", 5000);
  -->
  </script>
  [% END %]
</div>
[% END %]
