iutbay / yii2-kcfinder

KCFinder for Yii2
22 stars 19 forks source link

How to set 'uploadURL' from backend to frontend #3

Closed adiramardiani closed 9 years ago

adiramardiani commented 9 years ago

I have configure and set if upload from backend should insert into @frontend/web/uploads I configure :

'uploadURL' => Yii::$app->urlManagerFrontEnd->createUrl('uploads') //not working
//upload success but create folder in backend (not in frontend)
//but the url give true url (http://mywebsite.com) so cannot find

//or

'uploadURL' => Yii::getAlias('@web').'/../../frontend/web/uploads', //this is upload working but url in backend is '../../frontend' 
//so I cannot review image or image not show in textarea 
//because url is refer to src = '../../frontend/uploads/filename.xxx'
//i want to give url scr='http://admin.mywebsite.com/uploads/filename.xxx'
//note : i use Yii::getAlias('@frontend/web/uploads/') not working upload

//or
'uploadURL' => Yii::$app->urlManagerFrontEnd->createUrl('uploads'),
'uploadDir' => Yii::getAlias('@web').'/../../frontend/web/uploads',
//not working too

Is not working

klevron commented 9 years ago

Thanks, will take a look asap, or feel free to make a pull request

stmswitcher commented 9 years ago

Hey. I'm using symlinks for this. For example: I have a folder "images" in frontend/web and to access, manage and upload images from backend I've created a symlink "images" to the fronend's "images" folder.

vpadhariya commented 8 years ago

Hello, Is there any progress on this, as I am having same issue.