function sefUrlEncode($text, $level = 0, $and_replace = 'and') { $_this =& S2Router::getInstance(); if (isset($_this->__translit[$text])) { return $_this->__translit[$text]; } $text = str_replace(array('-', '&'), array(' ', $and_replace), $text); $translitText = cmsFramework::UrlTransliterate(trim($text)); $_this->__translit[$text] = $translitText; return $translitText; }