Actually out of one Forum becaume two. Now the one stays behind while the other moves to a new domain. Therefore I want to redirect the showthreads and forumdisplays to the new domain. The kriteria wheather to move shell be a list of forumids that have moved eg:
- Redirects if forumhome or thread of the following forumids: 41, 25, 28, 30, 34, 38, 36, 37, 23, 29, 32, 27, 35, 39, 33, 89, 79, 90, 31
- I want to use this code
PHP Code:
if ($forumid == "41" or $forumid == "25" or $forumid == "28" or $forumid == "30" or $forumid == "34" or $forumid == "38" or $forumid == "36" or $forumid == "37" or $forumid == "23" or $forumid == "29" or $forumid == "32" or $forumid == "27" or $forumid == "35" or $forumid == "39" or $forumid == "33" or $forumid == "89" or $forumid == "79" or $forumid == "90" or $forumid == "31") {
// the forumdisplay.php?.... and showthread.php?..... url
// shall be cut out in order to be put in into the header location again $headerurl
$goto ='www.your new server.de';
$goto.='/new extra subdir';
$goto.=$headerurl;
header("HTTP/1.1 301 Moved Permanently");
header("Location: http://www.newsolutions.de/forum-systemi-as400-i5-iseries/".$headerurl);
exit;
}
???????????????????????????????1
How do I get the
forumid in the forumdisplay.php and showthread.php
???????????????????????????????2
How do I extract one part of the url and put it in the variable $headerurl
Please help, I want to move the pagerank of about 30 thousend google entries!
Sincerely your from Berlin
Burgy Zapp
vB Version 3.64 compatible
Here is the code for the showthread.php and forumdisplay.php
post directly above the hook code (search for hook)
PHP Code:
// HACK RLP 301 move to DUKE
if ($forumid == "41" or $forumid == "25" or $forumid == "28" or $forumid == "30" or $forumid == "34" or $forumid == "38" or $forumid == "36" or $forumid == "37" or $forumid == "23" or $forumid == "29" or $forumid == "32" or $forumid == "27" or $forumid == "35" or $forumid == "39" or $forumid == "33" or $forumid == "89" or $forumid == "79" or $forumid == "90" or $forumid == "31") {
$goto ='www.your new server.de';
$goto.='/new extra subdir';
$goto.= $_SERVER["REQUEST_URI"];
header("HTTP/1.1 301 Moved Permanently");
header("Location: http://".$goto);
exit;
//echo "http://".$goto;
}
// HACK RLP 301 move to DUKE
Here is the code for the archive
post directly above the hook code (search for hook)
PHP Code:
// HACK RLP 301 move to DUKE
$threadinfo = fetch_threadinfo($t);
if ($threadinfo) {
$forumid = ($threadinfo['forumid']);
}
else {
$foruminfo = fetch_foruminfo($f, false);
$forumid = $foruminfo['forumid'];
}
if ($forumid == "41" or $forumid == "25" or $forumid == "28" or $forumid == "30" or $forumid == "34" or $forumid == "38" or $forumid == "36" or $forumid == "37" or $forumid == "23" or $forumid == "29" or $forumid == "32" or $forumid == "27" or $forumid == "35" or $forumid == "39" or $forumid == "33" or $forumid == "89" or $forumid == "79" or $forumid == "90" or $forumid == "31") {
$goto ='www.your new server.de';
$goto.='/new extra subdir';
$goto.= $_SERVER["REQUEST_URI"];
header("HTTP/1.1 301 Moved Permanently");
header("Location: http://".$goto);
exit;
// echo "http://".$goto;
}
// HACK RLP 301 move to DUKE
Giving back to comunity I do not support anything, while I need myself support
BZ