UniSharp / laravel-filemanager

Media gallery with CKEditor, TinyMCE and Summernote support. Built on Laravel file system.
https://unisharp.github.io/laravel-filemanager/
MIT License
2.08k stars 721 forks source link

Issue with routes and displaying uploaded images #826

Open yassersharaf opened 5 years ago

yassersharaf commented 5 years ago

Hello,

I'm using version 1.9.2 and php 7 with Laravel 5.7

I followed the installation guide but I have 2 issues:

1- when I add the routes with or without middleware protection

Route::group(['middleware' => 'auth'], function () { Route::get('/laravel-filemanager', '\UniSharp\LaravelFilemanager\controllers\LfmController@show'); Route::post('/laravel-filemanager/upload', '\UniSharp\LaravelFilemanager\controllers\UploadController@upload'); });

I get this error

Class UniSharp\LaravelFilemanager\controllers\LfmController does not exist

Screenshot: https://imgur.com/sZriybx

2- And when I remove them I can display the page of uploading and I can upload already to the storage/app/files directory itself here's the config

'use_package_routes' => true,
'middlewares' => ['web', 'auth'],
'url_prefix' => 'laravel-filemanager',

'base_directory' => 'public',
'images_folder_name' => 'photos',
'files_folder_name'  => 'files',
'shared_folder_name' => 'shares',
'thumb_folder_name'  => 'thumbs',

I can upload images as I said but when I try to browse images I get a wrong image path. The public directory isn't in the URL how to fix this please?

Screenshot: https://imgur.com/D0odDtS

xuandung38 commented 5 years ago

please reinstall laravel filemanager. composer require unisharp/laravel-filemanager:v2.0.0-alpha8

nathanael79 commented 5 years ago

@xuandung38 i already reinstall and still got that problem

lamtranb commented 5 years ago

Please change controllers to Controllers

xuandung38 commented 5 years ago

Qua laua rồi bạn hiền. Có thể họ chọn thư viện khác rồi

decodedmrq commented 5 years ago

Downgrade to laravel 5.8.*