We are experiencing a temporary problem with the foreign language section. Please try again later. We apologize for the inconvenience.
'.$site_url.'
'; exit(); } //modify all links $page = str_replace('
', '', $page); }else if($lang == "sv" or $lang == "ro" or $lang == "pl" or $lang == "no" or $lang == "hi" or $lang == "fi" or $lang == "da" or $lang == "cs" or $lang == "hr" or $lang == "bg"){ $translator = 'TRANSLATOR_GOOGLE'; $page = curlPage("http://64.233.179.104/translate_c","hl=en&langpair=en%7C".$lang."&u=http://".$site_url."%2F".$url.$args); //$page = "302 Moved"; if ((eregi("302 Moved",$page))) {// if it return an error $translator = 'TRANSLATOR_NONE'; echo '
We are experiencing a temporary problem with the foreign language section. Please try again later. We apologize for the inconvenience.
'.$site_url.'
'; exit(); } }else{ $translator = 'systran'; $page = curlPage("http://www.systranlinks.com/trans", "systran_lp=en_".$lang."&systran_id=http://www.appliedlanguage.com/&systran_url=http://".$site_url."/".$url.$args); if ((eregi("encountered an error",$page))) {// if it return an error $translator = 'TRANSLATOR_NONE'; echo '
We are experiencing a temporary problem with the foreign language section. Please try again later. We apologize for the inconvenience.
'.$site_url.'
'; exit(); } } //modify all links if($translator == 'TRANSLATOR_GOOGLE'){ $page = str_replace('href="http://64.233.179.104/translate_c?hl=en&langpair=en%7C'.$lang.'&u=http://'.$site_url, 'href="http://'.$site_url.'/'.$lang, $page); $page = str_replace('href="http://64.233.179.104/translate_c?hl=en&langpair=en%7C'.$lang.'&u=http://', 'href="http://', $page); $page = str_replace('%3F', '?', $page); $page = str_replace('%3D', '=', $page); $page = str_replace('%26', '&', $page); } else if($translator == 'systran'){ $page = str_replace('href="http://www.systranlinks.com/trans?systran_lp=xx_'.$lang.'&systran_id=http://www.appliedlanguage.com/&systran_url=http%3A%2F%2F'.$site_url, 'href="http://'.$site_url.'/'.$lang, $page); $page = str_replace('href="http://www.systranlinks.com/trans?systran_lp=xx_'.$lang.'&systran_id=http://www.appliedlanguage.com/&systran_url=http%3A', 'href="http:', $page); $page = str_replace('%7C', '&', $page); $page = str_replace('|', '&', $page); $page = str_replace('%3F', '?', $page); $page = str_replace('%2F', '/', $page); $page = str_replace('%3D', '=', $page); } //replace the javascript for the flags code $page = str_replace('
', flags(), $page); //rewrite the flags link because the translator changes it $flag_subtrings = returnSubstrings($page, '', ''); $flag = $flag_subtrings[0]; $flag_link = flags(); $page = str_replace($flag, $flag_link, $page); $result = $page; // save the result in the cache acmeCache::save($full_url, $result); return $result; } else{ return $result; } } echo translator(); ?>
|