+ set_up_language($squirrelmail_language, true);
+
+ displayHtmlHeader( $errTitle, '', false );
+
+ echo "<BODY TEXT=\"$color[8]\" BGCOLOR=\"$color[4]\" LINK=\"$color[7]\" VLINK=\"$color[7]\" ALINK=\"$color[7]\">\n\n" .
+ '<CENTER>';
+
+ if (isset($org_logo) && ($org_logo != '')) {
+ echo "<IMG SRC=\"$org_logo\" ALT=\"" . sprintf(_("%s Logo"), $org_name) .
+ "\"$width_and_height><BR>\n";
+ }
+ echo ( $hide_sm_attributions ? '' :
+ '<SMALL>' . sprintf (_("SquirrelMail version %s"), $version) . "<BR>\n".
+ ' ' . _("By the SquirrelMail Development Team") . "<BR></SMALL>\n" ) .
+ "<table cellspacing=1 cellpadding=0 bgcolor=\"$color[1]\" width=\"70%\"><tr><td>".
+ "<TABLE WIDTH=\"100%\" BORDER=\"0\" BGCOLOR=\"$color[4]\" ALIGN=CENTER>".
+ "<TR><TD BGCOLOR=\"$color[0]\" ALIGN=\"center\">".
+ "<FONT COLOR=\"$color[2]\"><B>" . _("ERROR") .
+ '</B></FONT></TD></TR>'.
+ '<TR><TD ALIGN="center">' . $errString . '</TD></TR>'.
+ "<TR><TD BGCOLOR=\"$color[0]\" ALIGN=\"center\">".
+ "<FONT COLOR=\"$color[2]\"><B>".
+ '<a href="' . $base_uri . 'src/login.php" target="' .
+ $frame_top . '">' .
+ _("Go to the login page") . "</a></B></FONT>".
+ '</TD></TR>'.
+ '</TABLE></td></tr></table></center></body></html>';
+}
+
+function error_box($string, $color) {
+ global $pageheader_sent;
+
+ if ( !isset( $color ) ) {
+ $color = array();
+ $color[0] = '#DCDCDC'; /* light gray TitleBar */
+ $color[1] = '#800000'; /* red */
+ $color[2] = '#CC0000'; /* light red Warning/Error Messages */
+ $color[4] = '#FFFFFF'; /* white Normal Background */
+ $color[7] = '#0000CC'; /* blue Links */
+ $color[8] = '#000000'; /* black Normal text */
+ }
+
+ $err = _("ERROR");
+
+ $ret = concat_hook_function('error_box', $string);
+ if($ret != '') {
+ $string = $ret;
+ }
+
+ /* check if the page header has been sent; if not, send it! */
+ if(!isset($pageheader_sent) && !$pageheader_sent) {
+ /* include this just to be sure */
+ include_once( SM_PATH . 'functions/page_header.php' );
+ displayHtmlHeader('SquirrelMail: '.$err);
+ $pageheader_sent = TRUE;
+ echo "<body text=\"$color[8]\" bgcolor=\"$color[4]\" link=\"$color[7]\" vlink=\"$color[7]\" alink=\"$color[7]\">\n\n";
+ }
+
+ echo ' <table width="100%" cellpadding="1" cellspacing="0" align="center"'.' border="0" bgcolor="'.$color[9].'">';
+ echo ' <tr><td>';
+ echo ' <table width="100%" cellpadding="0" cellspacing="0" align="center" border="0" bgcolor="'.$color[4].'">';
+ echo ' <tr><td ALIGN="center" bgcolor="'.$color[0].'">';
+ echo ' <font color="' . $color[2].'"><b>' . $err . ':</b></font>';
+ echo ' </td></tr>';
+ echo ' <tr><td>';
+ echo ' <table cellpadding="1" cellspacing="5" align="center" border="0">';
+ echo ' <tr>' . html_tag( 'td', $string."\n", 'left')
+ . '</tr>';
+ echo ' </table>';
+ echo ' </td></tr>';
+ echo ' </table></td></tr>';
+ echo ' </table>';
+}