<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

/**
 * Editor Class
 *
 * 编辑器
 *
 * @package     zsb
 * @subpackage      Controllers
 * @category        Controllers
 * @author      sun
 */
class Editor extends MY_Controller 
{
        
    /**
    * 解析函数
    *
    * @access public
    * @return void
    */
    public function __construct()
    {
        parent::__construct();
    }
    
    //房源编辑器
    public function house()
    {
		
        $edit_config['width'] = 820;
        $edit_config['height'] = 380;
        $edit_config['items'] = "'fontname', 'fontsize', '|', 'forecolor',
            'hilitecolor', 'bold', 'italic', 'underline', 'removeformat', '|', 
            'justifyleft', 'justifycenter', 'justifyright', 'insertorderedlist',
            'insertunorderedlist', '|', 'wordpaste', '|', 'image'";
        // 编辑器id
        $edit_config['edit_id'] = $this->input->get('id') ? $this->input->get('id') : 'remark';
        $this->load->view('/editor', $edit_config);
    }
    
    //房源模板的编缉器
    public function house_template()
    {
        $edit_config['width'] = 780;
        $edit_config['height'] = 380;
        $edit_config['items'] = "'fontname', 'fontsize', '|', 'forecolor',
            'hilitecolor', 'bold', 'italic', 'underline', 'removeformat', '|', 
            'justifyleft', 'justifycenter', 'justifyright', 'insertorderedlist',
            'insertunorderedlist'";
        $this->load->view('editor', $edit_config);
    }
}