zxbodya / yii2-tinymce

Yii2 extension, tinymce wysiwyg editor
17 stars 10 forks source link

Integrate with modules #5

Closed StagnantIce closed 8 years ago

StagnantIce commented 8 years ago

Hello, i want integrate your issue with some modules, how i can do this?

But elfinder not working with modules.

Create controller in each module is not good issue.

StagnantIce commented 8 years ago

Excelent work!

Add controller map

'controllerMap' => [
    'el-finder' => 'your_namespace\\ElFinderController'
]

Add slash to route

$this->fileManager = [ 'class' => TinyMceElFinder::className(), 'connectorRoute' => '/el-finder/connector', ];

And add slash to route, without alias

    return [
        'connector' => array(
            'class' => ConnectorAction::className(),
            'settings' => array(
                'root' => Yii::getAlias('@upload') . '/',
                'URL' => $url,
                'rootAlias' => 'Home',
                'mimeDetect' => 'none'
            )
        )
    ];

And work perfect.