Advertisement
janus57

fatal.php

Nov 27th, 2014
274
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 4.01 KB | None | 0 0
  1. <?php
  2. /***************************************************************************
  3.  *                                fatal.php
  4.  *                            -------------------
  5.  *   begin                : April 12, 2007
  6.  *   copyright          : (C) 2007 CrowkaiT
  7.  *   email                : crowkait@phpboost.com
  8.  *
  9.  *
  10.  *
  11.  ***************************************************************************
  12.  *
  13.  *   This program is free software; you can redistribute it and/or modify
  14.  *   it under the terms of the GNU General Public License as published by
  15.  *   the Free Software Foundation; either version 2 of the License, or
  16.  *   (at your option) any later version.
  17.  *
  18.  * This program is distributed in the hope that it will be useful,
  19.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  20.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  21.  * GNU General Public License for more details.
  22.  *
  23.  * You should have received a copy of the GNU General Public License
  24.  * along with this program; if not, write to the Free Software
  25.  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
  26.  *
  27. ***************************************************************************/
  28.  
  29. require_once '../kernel/begin.php';
  30.  
  31. echo '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
  32. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr" >
  33. <head>
  34.     <title>' . $LANG['error'] . '</title>
  35.     <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  36.     <link href="../templates/' . get_utheme() . '/theme/design.css" rel="stylesheet" type="text/css" media="screen" />
  37.     <link href="../templates/' . get_utheme() . '/theme/global.css" rel="stylesheet" type="text/css" media="screen" />
  38.     <link href="../templates/' . get_utheme() . '/theme/generic.css" rel="stylesheet" type="text/css" media="screen" />
  39.     <link href="../templates/' . get_utheme() . '/theme/bbcode.css" rel="stylesheet" type="text/css" media="screen" />
  40.     <link href="../templates/' . get_utheme() . '/theme/content.css" rel="stylesheet" type="text/css" media="screen" />
  41.     <link rel="shortcut" href="../favicon.ico" />
  42.     <style>
  43.         a:hover {
  44.         background-color:#000000;
  45.         color:#FFFFFF;
  46.         }
  47.     </style>
  48. </head>
  49. <body><br /><br /><br />';
  50. if ($_GET['error'] == 1 && $_GET['_err_stop'] == 1){
  51. echo '<div style="background-color:#F4F4F4; max-width:500px; margin: 0px auto; padding:15px;">
  52.     <a href="../"><img src="../images/autres/menu-2013/home-m-brh.png"></a><br /><br />
  53.    <strong>Nous sommes d&eacutesol&eacute, une erreur s\'est produite.</strong><br /><br />
  54.    L\'administrateur du site a &eacutet&eacute averti, veuillez revenir sur <a href="../"><strong>l\'accueil du site planet-truck.fr</strong></a><br />
  55.    Si l\'erreur persiste vous pouvez me contactez &agrave; l\'adresse suivante : mickael@planet-truck.fr <br /><br />
  56.    <strong>Voici plus de d&eacutetails sur l\'erreur :</strong>
  57.     <br /><br /></div>';
  58. }
  59.  
  60. //Récupération de l'erreur dans les logs.
  61. $errinfo = $Errorh->get_last__error_log();
  62. if (empty($errinfo))
  63.     list($errinfo['errno'], $errinfo['errstr'], $errinfo['errline'], $errinfo['errfile']) = array('-1', '???', '0', 'unknow');
  64.  
  65. $Template->set_filenames(array(
  66.     'error'=> 'member/error.tpl'
  67. ));
  68.  
  69. $class = $Errorh->get_errno_class($errinfo['errno']);
  70.    
  71. $Template->assign_vars(array(
  72.     'THEME' => get_utheme(),
  73.     'ERRORH_IMG' => 'stop',
  74.     'ERRORH_CLASS' => $class,
  75.     'C_ERRORH_CONNEXION' => false,
  76.     'C_ERRORH' => true,
  77.     'L_ERRORH' => sprintf($LANG[$class], $errinfo['errstr'], $errinfo['errline'], basename($errinfo['errfile'])),
  78.     'L_ERROR' => $LANG['error'],
  79.     'U_BACK' => '<a href="' . get_start_page() . '">' . $LANG['home'] . '</a>' . (!empty($_SERVER['HTTP_REFERER']) ? ' &raquo; <a href="' . url($_SERVER['HTTP_REFERER']) .'">' . $LANG['back'] . '</a>' : ' &raquo; <a href="javascript:history.back(1)">' . $LANG['back'] . '</a>'),
  80. ));
  81.  
  82. $Template->pparse('error');
  83.  
  84. echo '</body></html>';
  85.  
  86. require_once '../kernel/footer_no_display.php';
  87.  
  88. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement