Call Forwarding certain level ID

At a certain ID to reach a certain level, the page should be redirected.

Example: The site is located on level 1 and has the ID = 2

Call in frontend_render/init

Old version:

if ( isset( $LEVEL_ID[1]) ) {
   if ( $LEVEL_ID[1] == 2 )  {
//  header("Status: 301 Moved Permanently");
//  header("Location: http://www.example.com");
 
    headerRedirect($target='http://www.example.com', '301');
 
    exit();
  }
}


New version:

$match[1] = 1;                        // What level? (Array [1] must be filled)
if (replace_level_id($match) == 2) {  // Which pages ID ?
    headerRedirect($target='http://www.example.com', '301');
    exit();
}
english/phpwcms_replacer_rts/integrated-tags/level-tags/call-forwarding-certain-level-id.txt · Last modified: 2018/06/03 18:09 (external edit)
www.planmatrix.de www.chimeric.de Creative Commons License Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0