The following warnings occurred:
Warning [2] Undefined array key "threadviews_countguests" - Line: 745 - File: showthread.php PHP 8.1.31 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/showthread.php 745 errorHandler->error_callback
Warning [2] Undefined array key "allowautourl" - Line: 584 - File: inc/class_parser.php PHP 8.1.31 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/class_parser.php 584 errorHandler->error_callback
/inc/class_parser.php 228 postParser->parse_mycode
/inc/functions_post.php 830 postParser->parse_message
/showthread.php 916 build_postbit
Warning [2] Undefined property: MyLanguage::$thread_modes - Line: 46 - File: showthread.php(1650) : eval()'d code PHP 8.1.31 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/showthread.php(1650) : eval()'d code 46 errorHandler->error_callback
/showthread.php 1650 eval




Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Personalized 404 page ?
#2
In index.php
find
Code:
$file = "data/pages/". $id .".xml";
    $file_403 = "data/other/403.xml";
    if (! file_exists($file)) {
        if (file_exists($file_403)) {
            $file = $file_403;
            include('admin/inc/403-mailer.php');
        }
    }

replace with
Code:
$file = "data/pages/". $id .".xml";
    $preferred_file = "data/pages/404.xml";    
    $file_403 = "data/other/403.xml";
    if (! file_exists($file)) {
        if (file_exists($preferred_file)) {
            $file = $preferred_file;
            }else{
            $file = $file_403;
            }
            include('admin/inc/403-mailer.php');
        }
basically - lines - 36 through 46 of index.php

what this will do is look for the existence of a page with a slug of 404 and it will serve that page when needed - if that page doesn't exist it defaults to the standard error page

HTH

saul
http://www.twitter.com/sauldraws
Reply


Messages In This Thread
Personalized 404 page ? - by Faramir - 2009-09-29, 00:08:36
Personalized 404 page ? - by sauldraws - 2009-12-25, 02:02:46
Personalized 404 page ? - by Zegnåt - 2009-12-25, 08:22:41
Personalized 404 page ? - by sauldraws - 2009-12-25, 09:43:49



Users browsing this thread: 1 Guest(s)