

$fileName = "" // random number + file name $rnd = rand() // generate random number between 0-9999 $uploadedFile = CUploadedFile::getInstanceByName('file') 'imageGetJson' => Yii::app()->createAbsoluteUrl('admin/event/listImages')))) ?> RedactorRow($model,'descr', array('options' => array('imageUpload' => Yii::app()->createAbsoluteUrl('admin/event/imageUpload'), Yii-RedactorJS-Widget Using with a model Using with a model and a mini toolbar and different language Using with a model and custom toolbar options Using with a name and value Yii Widget for the WYSIWYG RedactorJS editor Project Page Examples Documentation Yii Widget Github Project Page Requirements JQuery > 1.7.
#YII REDACTOR CODE#
If you click cancel on the upload window then re-open it, the file I uploaded shows up in the list of files on the server and can be inserted.ĮDIT: Got it working, here’s the controller code for those interested.

It has a hybrid interface that can be customized according to your needs. Suitable for creating and editing common texts for the web, which may also include images, video, embed code. The image uploads work, but after you select the file to upload the file is transferred and stored but does not show in the window to insert it into the editor area. Redactor X A simple and fast tool for everyday tasks of creating and editing texts on the web. It’s a current version of redactor (Dec 2012 I believe).
#YII REDACTOR FULL#
'title' => Yii::t('kveditor', 'Toggle full screen'),I’m trying to implement file uploads using the redactor editor bundled with Yii-booster. 'title' => Yii::t('kveditor', 'Pretty format'),

The following is the default button configuration, which can be overridden via this property. Set as an array of button names (matching the plugin's actions) and the values being an array of button label and title. 'matches' => new JsExpression("/(text|application)\\/(x-)?vb(a|script)/i"),Īrray, the configuration of the toolbar buttons. I've tried to edit their css but it didn't work. 'matches' => new JsExpression("/\\/x-handlebars-template|\\/x-mustache/i"), I'm using Yii2 Redactor box, extension from: I want to change size of the textarea but I don't know how, it not mention in their document. The following are the plugin settings automatically enabled within pluginOptions for each of the presets above: You can also set a preset and override the settings for the preset in pluginOptions.ĬodeMirror::PRESET_JS or 'js' for Javascript codeĬodeMirror::PRESET_JSON or 'json' for Javascript codeĬodeMirror::PRESET_HTML or 'html' for HTML codeĬodeMirror::PRESET_PHP or 'php' for PHP codeĬodeMirror::PRESET_GFM or 'gfm' for Github Flavored Markdown code Set this to null or false if you do not wantĪny preset. When a preset is selected, it will be merged along with Krajee default preset settings This can be one of the PRESET constants mentioned below. Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Sagittis mollis, tellus est malesuada tellus, at luctus turpis elit sit amet quam. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Vestibulum erat wisi, condimentum sed,Ĭommodo vitae, ornare sit amet, wisi. Pellentesque habitant morbi tristique senectus et netus et malesuada famesĪc turpis egestas.
