public function get_columns() {
        if (isset($this->_columns)) {
            return $this->_columns;
        }

        global $USER, $CFG;

        $filename = $CFG->tempdir.'/csvimport/'.$this->_type.'/'.$USER->id.'/'.$this->_iid;
        if (!file_exists($filename)) {
            return false;
        }
        $fp = fopen($filename, "r");
        $line = fgetcsv($fp);
        fclose($fp);
        if ($line === false) {
            return false;
        }
        $this->_columns = $line;
        return $this->_columns;
    }
public function get_columns() {
        if (isset($this->_columns)) {
            return $this->_columns;
        }

        global $USER, $CFG;

        $filename = $CFG->tempdir.'/csvimport/'.$this->_type.'/'.$USER->id.'/'.$this->_iid;
        if (!file_exists($filename)) {
            return false;
        }
        $fp = fopen($filename, "r");
        $line = fgetcsv($fp);
        fclose($fp);
        if ($line === false) {
            return false;
        }
        $this->_columns = $line;
        return $this->_columns;
    }
public function get_columns ( ) { if ( isset ( $ this -> _columns ) ) { return $ this -> _columns ; } global $ USER , $ CFG ; $ filename = $ CFG -> tempdir . '/csvimport/' . $ this -> _type . '/' . $ USER -> id . '/' . $ this -> _iid ; if ( ! file_exists ( $ filename ) ) { return false ; } $ fp = fopen ( $ filename , "r" ) ; $ line = fgetcsv ( $ fp ) ; fclose ( $ fp ) ; if ( $ line === false ) { return false ; } $ this -> _columns = $ line ; return $ this -> _columns ; }
Returns list of columns

@return array
Returns list of columns