Created
January 23, 2012 14:30
-
-
Save jamiefdhurst/1663400 to your computer and use it in GitHub Desktop.
Awesome error function
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function errorpage($message, $cuscon = false, $goBack = true, $exit = true) { | |
if (!$cuscon) { | |
echo " | |
<table width=\"100%\"> | |
<tr> | |
<td> | |
<table width=\"100%\" align=\"center\" cellpadding=\"0\" cellspacing=\"0\"> | |
<tr> | |
<td align=\"center\"> | |
<img src=\"linghead.jpg\" alt=\"Wahh!\" title=\"Wahh!\" /><br /><span class=\"title_red\" style=\"font-size: 36px;\">WAHHH!!!<br />{$message}</span> | |
" . ($goBack ? "<br /><br /><a href=\"javascript: history.go(-1)\"><span style=\"font-size: 16px; font-weight: bold;\"><-- Go Back</span></a>" : "") . " | |
</td> | |
</tr> | |
</table> | |
</td> | |
</tr> | |
</table>"; | |
} else { | |
echo $cuscon; | |
} | |
if($exit) | |
exit; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment