=================================================================== RCS file: /home/cvsd/home/cvs/Metafox/rewrite.php,v retrieving revision 1.1 retrieving revision 1.2 diff -u -p -r1.1 -r1.2 --- Metafox/rewrite.php 2012/05/15 17:47:56 1.1 +++ Metafox/rewrite.php 2012/05/17 08:57:16 1.2 @@ -43,10 +43,13 @@ $link = $_GET['link']; require_once 'cfgldr.inc.php'; +$link_file_type = -1; + // type 0 if ($link == 'index.php' || strlen($link) <= 0) { + $link_file_type = 0; $setvars = array_keys($_GET); if ( $ezin_cfg['link_file_type'] != 0 && $ezin_cfg['link_redirect'] > 0 @@ -110,6 +113,7 @@ if ($link == 'index.php' // type 1 if (in_array($link, array('section.php', 'article.php', 'author.php', 'print.php'))) { + $link_file_type = 1; if ( $ezin_cfg['link_file_type'] != 1 && $ezin_cfg['link_redirect'] > 0) { // redirect @@ -143,6 +147,7 @@ if (in_array($link, array('section.php', if (strlen($link) > 0 && strtolower(substr($link, -4)) != '.php') { + $link_file_type = 2; $args = explode('/', $link); //print_r($args); @@ -224,4 +229,11 @@ if (strlen($link) > 0 } +// notfound +if ($link_file_type == -1) { + require_once 'cfgldr.inc.php'; + $ezin_cgi['input'] = 'notfound'; + require_once 'index.php'; +} + ?>