I see this code in my php translator
public function translate($from, $to, $text, $format = 'Raw' )
{
if(empty($to) || empty($text)) {
$this->getErrorResponse($
return;
}
// what is this line doing? my $from is empty where is $this->from coming from?
$this->from = (!empty($this->from )) ? $this->sanitize($from) : '';
$this->to = $this->sanitize($to);
$this->textToTranslate = $this->sanitize($text);
$this->format = $format;
$request = $this->getRequest(self::
echo $request."<br/>";
$response = file_get_contents( $request, 0, $this->context );
if(!empty($response) && isset($response)){
$this->getSuccessResponse($response);
} else {
$this->getErrorResponse($response, self::UNEXPECTED_ERROR, $missing );
}
}