S
S
s0prano2018-12-12 05:47:44
Laravel
s0prano, 2018-12-12 05:47:44

Problem with file upload paths?

I uploaded the project to the host, after which I specified the folder from which to load the project - public_html, the site is working, the files are uploading to the wrong directory, the Voyager admin panel.
Loads to: /www/storage/app/public/posts/...
Takes paths: /www/public/storage/posts/...
How to solve this problem? Thanks in advance.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
K
Kairat Ubukulov, 2018-12-12
@ubukulov

Try like this:
$path = base_path() . "/storage/posts/";

V
Vasyl Fomin, 2018-12-13
@fomvasss

"then specified the folder from which to load the project - public_html". If Laravel itself is in public_html, then you need to specify the public_html/public folder in the server configs

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question