Imperavi Redactor Widget

Imperavi Redactor WYSIWYG widget(OEM 授权用于 Yii)。「Imperavi Redactor WYSIWYG widget (OEM-licensed for Yii)」

Github星跟踪图

Imperavi Redactor Widget

ImperaviRedactorWidget is a wrapper for Imperavi Redactor,
a high quality WYSIWYG editor.

Note that Imperavi Redactor itself is a proprietary commercial copyrighted software
but since Yii community bought OEM license you can use it for free with both Yii 1.1.x and Yii 2.0.x.

This repository contains an extension for 1.1.x. For 2.0.x check https://github.com/vova07/yii2-imperavi-widget.

Usage

First, import the widget class file

Yii::import('ext.imperavi-redactor-widget.ImperaviRedactorWidget');

Next, call the widget:

$this->widget('ImperaviRedactorWidget', array(
	// You can either use it for model attribute
	'model' => $my_model,
	'attribute' => 'my_field',

	// or just for input field
	'name' => 'my_input_name',

	// Some options, see http://imperavi.com/redactor/docs/
	'options' => array(
		'lang' => 'ru',
		'toolbar' => false,
		'iframe' => true,
		'css' => 'wym.css',
	),
));

Alternatively you can attach Redactor to already existing DOM element by calling:

$this->widget('ImperaviRedactorWidget', array(
	// The textarea selector
	'selector' => '.redactor',
	// Some options, see http://imperavi.com/redactor/docs/
	'options' => array(),
));

The redactor plugins plugged in with packages of resources.

$this->widget('ImperaviRedactorWidget', array(
	'selector' => '.redactor',
	'options' => array(
		'lang' => 'ru',
	),
	'plugins' => array(
		'fullscreen' => array(
			'js' => array('fullscreen.js',),
		),
		'clips' => array(
			// You can set base path to assets
			'basePath' => 'application.components.imperavi.my_plugin',
			// or url, basePath will be ignored.
			// Defaults is url to plugis dir from assets
			'baseUrl' => '/js/my_plugin',
			'css' => array('clips.css',),
			'js' => array('clips.js',),
			// add depends packages
			'depends' => array('imperavi-redactor',),
		),
	),
));

主要指标

概览
名称与所有者yiiext/imperavi-redactor-widget
主编程语言JavaScript
编程语言PHP (语言数: 3)
平台
许可证Other
所有者活动
创建于2011-08-19 08:39:43
推送于2017-05-09 16:45:25
最后一次提交2017-02-28 21:03:23
发布数47
最新版本名称v1.3.18 (发布于 )
第一版名称v0.7 (发布于 2012-09-11 13:59:13)
用户参与
星数406
关注者数91
派生数152
提交数125
已启用问题?
问题数110
打开的问题数4
拉请求数14
打开的拉请求数1
关闭的拉请求数11
项目设置
已启用Wiki?
已存档?
是复刻?
已锁定?
是镜像?
是私有?