public function readResponse()
    {
        $response = $this->recvStr();
        $vals = explode(self::SEP, $response);
        if ($vals[0] != 0) {
            //error occured
            return new ErrorMessage(isset($vals[2]) ? $vals[2] : '', $vals[0]);
        } else {
            array_shift($vals); // skip error code
            $numCols = intval(array_shift($vals));
            $vals = array_map(array($this, 'decodeString'), $vals);
            $result = array_chunk($vals, $numCols);

            return $result;
        }
    }
public function readResponse()
    {
        $response = $this->recvStr();
        $vals = explode(self::SEP, $response);
        if ($vals[0] != 0) {
            //error occured
            return new ErrorMessage(isset($vals[2]) ? $vals[2] : '', $vals[0]);
        } else {
            array_shift($vals); // skip error code
            $numCols = intval(array_shift($vals));
            $vals = array_map(array($this, 'decodeString'), $vals);
            $result = array_chunk($vals, $numCols);

            return $result;
        }
    }
public function readResponse ( ) { $ response = $ this -> recvStr ( ) ; $ vals = explode ( self :: SEP , $ response ) ; if ( $ vals [ 0 ] != 0 ) { //error occured return new ErrorMessage ( isset ( $ vals [ 2 ] ) ? $ vals [ 2 ] : '' , $ vals [ 0 ] ) ; } else { array_shift ( $ vals ) ; // skip error code $ numCols = intval ( array_shift ( $ vals ) ) ; $ vals = array_map ( array ( $ this , 'decodeString' ) , $ vals ) ; $ result = array_chunk ( $ vals , $ numCols ) ; return $ result ; } }
Read response from server

@return ErrorMessage | array
Read response from server