7.2代码如下:

  • <?php
  • define(‘CURSCRIPT’, ‘index’);
  • require_once ‘./include/common.inc.php’;
  • include template(‘header’);
  • print <<<HTML
  • <div id=”nav”><a href=”$indexname”>$bbname</a> » 您打开的页面不存在</div>
  • <div id=”wrap”>
  • <style type=”text/css”>
  • <!–
  • .txt404 {
  •     line-height:120px;
  •     text-align:center;
  •     height:240px;
  •     padding:120px 0px;
  •     font-weight: 600;
  •     font-family: Verdana, Arial, Helvetica, sans-serif;
  •     overflow:hidden;
  • }
  • .txt404 p{
  •     padding:0px;
  •     margin:0px;
  •     color: #FF6600;
  •     font-size: 130px;
  • }
  • .txt404 p.notfound {
  •     color:#e5e5e5;
  •     font-size:80px;
  • }
  • –>
  • </style>
  • <div>
  • <p>404</p><p>not found</p>
  • </div>
  • </div>
  • HTML;
  • include template(‘footer’);
  • ?>

 

X2.0代码如下

  • <?php
  • require ‘./source/class/class_core.php’;
  • $discuz = & discuz_core::instance();
  • $discuz->cachelist = $cachelist;
  • $discuz->init();
  • $navtitle = ‘404’;
  • include template(‘common/header’);
  • print <<<HTML
  • <div id=”pt”><div><a href=”./” title=”{lang homepage}”>$_G[setting][bbname]</a><em>&raquo;</em>你访问的页面不存在</div></div>
  • <style type=”text/css”>
  • .txt404 {
  •     line-height:130px;
  •     text-align:center;
  •     height:260px;
  •     padding:110px 0px;
  •     font-weight: bold;
  •     font-family: Georgia, “Times New Roman”, Tahoma, Verdana, Arial;
  •     overflow:hidden;
  • }
  • .txt404 p{
  •     padding:0px;
  •     margin:0px;
  •     color: #FF6600;
  •     font-size: 140px;
  • }
  • .txt404 p.notfound {
  •     color:#e5e5e5;
  •     font-size:80px;
  • }
  • </style>
  • <div><p>404</p><p>not found</p></div>
  • HTML;
  • include template(‘common/footer’);
  • ?>