public function import_essay($question) {
        // Get common parts.
        $qo = $this->import_headers($question);

        // Header parts particular to essay.
        $qo->qtype = 'essay';

        $qo->responseformat = $this->getpath($question,
                array('#', 'responseformat', 0, '#'), 'editor');
        $qo->responsefieldlines = $this->getpath($question,
                array('#', 'responsefieldlines', 0, '#'), 15);
        $qo->responserequired = $this->getpath($question,
                array('#', 'responserequired', 0, '#'), 1);
        $qo->attachments = $this->getpath($question,
                array('#', 'attachments', 0, '#'), 0);
        $qo->attachmentsrequired = $this->getpath($question,
                array('#', 'attachmentsrequired', 0, '#'), 0);
        $qo->graderinfo = $this->import_text_with_files($question,
                array('#', 'graderinfo', 0), '', $this->get_format($qo->questiontextformat));
        $qo->responsetemplate['text'] = $this->getpath($question,
                array('#', 'responsetemplate', 0, '#', 'text', 0, '#'), '', true);
        $qo->responsetemplate['format'] = $this->trans_format($this->getpath($question,
                array('#', 'responsetemplate', 0, '@', 'format'), $this->get_format($qo->questiontextformat)));

        return $qo;
    }