<?php

if (!defined('BASEPATH')) {
    exit('No direct script access allowed');
}

/**
 * @author Igor Ratsun
 */
class Rtgc_html extends \Rtgc_textarea
{

    protected $field_xss_clean = false;
    protected $options = [
        'class' => 'span12',
        'rows'  => '20',
    ];
    
    public function column($value = '', $data = [])
    {
        return '<iframe srcdoc="' . htmlspecialchars($value) . '" style="width: 100%; min-height: 200px"></iframe>';
    }

    public function field($name = '', $value = NULL)
    {
        return '<textarea class="' . $this->options['class'] . '" rows="' . $this->options['rows'] . '" name="' . $name . '">' . $value . '</textarea>';
    }

}
