I have Laravel website saving images viya controller, I uploaded the project on server host, in public_html folder I put public folder files. other folders and files put on folder outside public_html
/home/domain_user
public_html
|__ images
project_folder
|__app
|__bootstrap
|__ public
|__images
when I save Images it saved in project_folder->public->images and when i used assets to view images it use images in :public_html->images
save image code :
$image_name=$post->id.'_'.$image_counter.'.jpg';
$image->move(public_path().'/images/posts/', $image_name);
view image code :
$image='images/posts/'.$post->id.'_1.jpg';
<img class="img-fluid" src="{{ asset($image) }}" alt="Third slide">
How can I save and vuew image to and from same path?