Witam,
Zainstalowałem
Advanced phpBB3 SEO mod Rewrite 0.4.4 Wszystko działa bez problemu.
Jednak gdy chcę zmienić znaki tzn np 'ą' na 'a' to mam pewien problem
otóż w pliku
phpbb_seo/phpbb_seo_class.php
mam linie która wyglada tak:
Kod: Zaznacz cały
function format_url( $url, $type = 'topic' ) {
$url = preg_replace('`\[.*\]`U','',$url);
$url = htmlentities($url, ENT_COMPAT, 'utf-8');
$url = preg_replace( '`&([a-z]+)(acute|uml|circ|grave|ring|cedil|slash|tilde|caron|lig);`i', "\\1", $url );
$url = preg_replace( $this->seo_opt['url_pattern'] , '-', $url);
$url = strtolower(trim($url, '-'));
return empty($url) ? $type : $url;
}
i według Twojej instrukcji zmieniam ją tak:
Kod: Zaznacz cały
function format_url( $url, $type = 'topic' ) {
$url = preg_replace('`\[.*\]`U','',$url);
$url = htmlentities($url, ENT_COMPAT, $this->encoding);
$this->seo_opt['url_find'] = array (
utf8_chr(260), utf8_chr(261),
utf8_chr(262), utf8_chr(263),
utf8_chr(280), utf8_chr(281),
utf8_chr(321), utf8_chr(322),
utf8_chr(323), utf8_chr(324),
utf8_chr(346), utf8_chr(347),
utf8_chr(377), utf8_chr(378),
utf8_chr(379), utf8_chr(380)
);
$this->seo_opt['url_replace'] = array('a', 'a', 'c', 'c', 'e', 'e', 'l', 'l', 'n', 'n', 's', 's', 'z', 'z', 'z', 'z');
$url = str_replace($this->seo_opt['url_find'],$this->seo_opt['url_replace'], $url);
$url = preg_replace( '`&([a-z]+)(acute|uml|circ|grave|ring|cedil|slash|tilde|caron|lig);`i', "\\1", $url );
$url = preg_replace( $this->seo_opt['url_pattern'] , '-', $url);
$url = strtolower(trim($url, '-'));
return empty($url) ? $type : $url;
}
Lecz to nic nie daje, wciąż literki się nie zmieniają
Pozdrawiam.
