모든 것이 잘 갑자기 일하고있다면 그것은 다음 하나 가능성은 귀하 번역 제공자 (일부 구성은 새로운 MOD 일부 소프트웨어 업데이 트 추가, 변경되었습니다 다른 사람들이)와 문제를 가지고되지 않습니다.
당신과 함께 문제를 확인하는 것은 매우 쉬운 방법이있다 있나 구글 API V1 아니면 다른 곳에 있습니다. 확인하려면 그냥 이러한 콘텐츠로 새 PHP 파일을 만드십시오 :
자네가 찾을 수이 파일은 vBET do-not-upload/tool s/googletest.php에 팩
PHP Code:
<?php
echo "Starting translation test for Google API v1<br/>\n";
$connection = curl_init();
curl_setopt($connection, CURLOPT_URL, 'http://ajax.googleapis.com/ajax/services/language/translate?v=1.0&format=html&langpair=pl|en&q=witaj');
curl_setopt($connection, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax)');
//curl_setopt($connection, CURLOPT_FOLLOWLOCATION, 1);
curl_setopt($connection, CURLOPT_RETURNTRANSFER, 1);
$time = microtime(true) * 1000;
$result = curl_exec($connection);
$time = microtime(true) * 1000 - $time;
echo 'Test result: '.$result."<br/>\n";
echo 'Test error: '.curl_error($connection)."<br/>\n";
curl_close($connection);
echo 'Connection time (ms): '.$time;
?>
혹시 구글을 사용 API V2 이 코드를 사용하여 -도이 파일은 우리의 다음 릴리스에 포함됩니다 :
PHP Code:
<?php
require_once('./global.php');
echo "Starting translation test for Google API v2<br/>\n";
$connection = curl_init();
curl_setopt($connection, CURLOPT_URL, 'https://www.googleapis.com/language/translate/v2?key='.$vbulletin->options['vbenterprisetranslator_googleapikeyv2'].'&format=html&q=witaj&target=en');
curl_setopt($connection, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax)');
//curl_setopt($connection, CURLOPT_FOLLOWLOCATION, 1);
curl_setopt($connection, CURLOPT_RETURNTRANSFER, 1);
$time = microtime(true) * 1000;
$result = curl_exec($connection);
$time = microtime(true) * 1000 - $time;
echo 'Test result: '.$result."<br/>\n";
echo 'Test error: '.curl_error($connection)."<br/>\n";
curl_close($connection);
echo 'Connection time (ms): '.$time;
?>
서버 (사용자 포럼 루트)에 업로드하여 브라우저에서 그것에 URL을 넣어. 모든 확인을 경우 대답을 얻을 것이다 :
Code:
Starting transaltion test
Test result: {"responseData": {"translatedText":"Welcome"}, "responseDetails": null, "responseStatus": 200}
Test error:
이 오류 메시지가 나타납니다 아무런 가치와 결과 상태가 200도 없습니다. 의미 : 모든 괜찮습니다.
어디 Google로부터 응답을 차단하면되는 것 같은데 것입니다 :
Code:
{"responseData": null, "responseDetails": "Suspected Terms of Service Abuse, please contact ajaxapis-support@google.com.", "responseStatus": 403}
어디 차단된 경우 - 메시지가시키는대로 Google에 씁니다. 그것은 우리가 그 이유를 찾을 수 있도록, 어쩌면 그것이 뭔가 실수가있다, 어쩌면 당신은 Google의 TOS에 더 잘 맞는 게 변경됩니다. 문제가 해결되면 어쨌든 구글 쉽게 액세스를 되찾는 
당신이 네트워크 문제가있다면 그 결과는 빈 것이고 오류가 (즉, 무슨 일이 일어 났는지 얘기합니다 : 호스트 'ajax.googleapis.com'를 해결할 수 없습니다). 당신은 (연결이 최대 시간이 초과 때까지) 출력을 볼 수 있습니다 전에 걸릴 수 있습니다 이러한 경우에 있습니다.
네트워크 문제 예제 :
Code:
Starting translation test
Test result:
Test error: Failed to connect to 74.125.95.95: Network is unreachable
Connection time (ms): 70.96484375
당신은 무엇을해야합니까?
첫째 : 방화벽이 구글에 대한 액세스를 차단하지 않습니다 확인하십시오.
둘째 : 당신의 호스트 공급자와 연락하여 연결 문제에 대해 물어해야
여러분은 다음 모든 또는 아무것도 "번역 테스트를 시작"을 참조하면 대부분의 아마 당신의 PHP 모듈에 컬 설치되어 있지 않습니다.
. 당신은 마이크로 소프트 API를 사용하는 경우, 새로운 PHP 파일을 생성하고 그 안에 코드를 넣어 :
PHP Code:
<?php
require_once('./global.php');
echo "Starting translation test MS<br/>\n";
$connection = curl_init();
curl_setopt($connection, CURLOPT_URL, 'http://api.microsofttranslator.com/V2/Ajax.svc/Translate?appId='.$vbulletin->options['vbenterprisetranslator_microsoftappid'].'&from=pl&to=en&options={%22ContentType%22:%22text/html%22}&text=witaj');
curl_setopt($connection, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax)');
//curl_setopt($connection, CURLOPT_FOLLOWLOCATION, 1);
curl_setopt($connection, CURLOPT_RETURNTRANSFER, 1);
$time = microtime(true) * 1000;
$result = curl_exec($connection);
$time = microtime(true) * 1000 - $time;
echo 'Test result: '.$result."<br/>\n";
echo 'Test error: '.curl_error($connection)."<br/>\n";
curl_close($connection);
echo 'Connection time (ms): '.$time;
?>
루트 포럼 폴더에서 서버에 업로드하고, 브라우저에 해당 링크를 넣어보다.
이 같은 나타납니다 :
PHP Code:
Starting translation test
Test result: "Hello"
Test error:
Connection time (ms): 272.083984375
만약 뭔가 잘못 되 면 당신이 오류가 발생, 즉, 만약 당신이 넣어 잘못 Microsoft ID:
PHP Code:
Starting translation test
Test result: "ArgumentException: Invalid appId Parameter name: appId xxx"
Test error:
Connection time (ms): 416.24194335938
당신은 신중하게 한 번 더하여 Microsoft ID를 붙여넣기해야보다
또한 당신이 의미 하는 (와 다른 ID 값),이 오류 메시지를 얻을 수 있습니다. microsoft에 의해 차단:
PHP Code:
Starting translation test MS
Test result: "InvalidOperationException: : ID=3641.V2_Json.Translate.365033CA"
Test error:
Connection time (ms): 237.756103516
이 경우 microsoft 기술 지원부에 메일을 보내도록 해야 합니다. mtcont@microsoft.com
이 콘텐츠를 포함:
-microsoft 번역기 API id
-즉, 오류 코드를 전체: InvalidOperationException:: ID=3641.V2_Json.Translate.365033CA
-문제를 설명 하는-그것 나타나면 등등.