If ($uploadedFile->saveAs(Yii::app()->basePath. $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'), 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 offers a JQuery API and has a wide set of plugins such as for image management, table formatting, and fullscreen editing. Yii Framework Forum PHP7.2 Fail to instantiate yii\redactor\RedactorModule' Yii 2.0 Installation and Setup steward (Steward) March 10, 2019, 7:12pm 1 I think this started after upgrading to php 7.2 I have no clue where to start looking. It has an extremely clean and fast user interface, while also providing a platform for powerful extensions. 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 is a powerful rich text editor created by Imperavi. It’s a current version of redactor (Dec 2012 I believe). I’m trying to implement file uploads using the redactor editor bundled with Yii-booster. Reference: Protect Your Uploads Folder with. 'uploadDir' => => You need to create uploads folder and chmod and set security for folder upload Or if you want to change the upload directory. 'redactor' => 'yii\redactor\RedactorModule', ConfigureĪdd to config file (config/web.php or common\config\main.php) 'modules' => [ To the require section of your composer.json. The preferred way to install this extension is through composer.Įither run php composer.phar require -prefer-dist yiidoc/yii2-redactor "*" Original yiidoc/yii2-redactor Readme: Installation Integrated CFDan's clipboardPaste plugin and added clipboard upload action. Integrate Redactor-10-clipboardPaste-plugin Contribute to yiidoc/yii2-redactor development by creating an account on GitHub. 'class' => 'yii\redactor\RedactorModule', Extension Redactor WYSIWYG for Yii2 framework. The guest user file path is still 'guest'. When set, this hides logged in user id's in file paths and uses a common folder for all logged in users. 'removePastedImagesMessage' => "Please upload images via filemanager or drag'n'drop",Īdditional config option added - authUserDir (default blank, allowed characters a-zA-Z0-9 only) The preferred way to install this extension is through composer. removePastedImagesMessage (default blank)Īdditional option to tell users the correct way to upload images. removePastedImages (default false)Īdditional option to remove images pasted in to content (as base64 data) - less restrictive than pastePlainText. Changes English (UK) language added 'clientOptions' => [ 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. Has not been published on packagelist yet. This version is a fork of yiidoc/yii2-redactor to allow some additionalįor install, replace "yiidoc/" with "stump90/" along with a repository if this
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |