Ich habe schon mit Version 4.2 Probleme bei der Installation gehabt eben wegen mod_rewrite.
Ich kann auf meinem Server die module auf jede Domain einzelnd aktivieren und bearbeiten. Das habe ich auch nochmal in der htaccess getestet.
z.B.
RewriteEngine On
RewriteBase /
RewriteRule ^ http://www.google.com [R]
So kann man testen ob mod_rewrite aktiv ist.
Mir wurde es dann zu dumm. Habe quelltext bearbeitet und jetzt hat die installation geklappt.
Bei 4.3 habe ich das selbe Problem gehabt. Musste auch den quelltext bescheissen.
In der oxsysrequirements.php habe ich folgendes geändert:
Alter code:
public function checkModRewrite()
{
$iModStat = null;
$sHost = $_SERVER['HTTP_HOST'];
$sScript = $_SERVER['SCRIPT_NAME'];
if ( $sScript && $rFp = @fsockopen( $sHost, 80, $iErrNo, $sErrStr, 10 ) ) {
$sScript = str_replace( basename($sScript), '../admin/test.php', $sScript );
$sReq = "POST $sScript HTTP/1.1
";
$sReq .= "Host: $sHost
";
$sReq .= "User-Agent: oxid setup
";
$sReq .= "Content-Type: application/x-www-form-urlencoded
";
$sReq .= "Content-Length: 0
"; // empty post
$sReq .= "Connection: close
";
$sOut = '';
fwrite( $rFp, $sReq );
while ( !feof( $rFp ) ) {
$sOut .= fgets( $rFp, 100 );
}
fclose( $rFp );
$iModStat = ( strpos( $sOut, 'mod_rewrite_on' ) !== false ) ? 2 : 0;
} else {
if ( function_exists( 'apache_get_modules' ) ) {
// it does not assure that mod_rewrite is enabled on current host, so setting 1
$iModStat = in_array( 'mod_rewrite', apache_get_modules() ) ? 1 : 0;
} else {
$iModStat = -1;
}
}
return $iModStat;
}
Neuer Code:
public function checkModRewrite()
{
$iModStat = null;
$sHost = $_SERVER['HTTP_HOST'];
$sScript = $_SERVER['SCRIPT_NAME'];
if ( $sScript && $rFp = @fsockopen( $sHost, 80, $iErrNo, $sErrStr, 10 ) ) {
$sScript = str_replace( basename($sScript), '../admin/test.php', $sScript );
$sReq = "POST $sScript HTTP/1.1
";
$sReq .= "Host: $sHost
";
$sReq .= "User-Agent: oxid setup
";
$sReq .= "Content-Type: application/x-www-form-urlencoded
";
$sReq .= "Content-Length: 0
"; // empty post
$sReq .= "Connection: close
";
$sOut = 'mod_rewrite_on';
fwrite( $rFp, $sReq );
while ( !feof( $rFp ) ) {
$sOut .= fgets( $rFp, 100 );
}
fclose( $rFp );
$iModStat = ( strpos( $sOut, 'mod_rewrite_on' ) !== false ) ? 2 : 0;
} else {
if ( function_exists( 'apache_get_modules' ) ) {
// it does not assure that mod_rewrite is enabled on current host, so setting 1
$iModStat = in_array( 'mod_rewrite', apache_get_modules() ) ? 1 : 0;
} else {
$iModStat = -1;
}
}
return $iModStat;
}
Funktioniert alles. SEO etc.