pt844931's avatar

Problem in create SymLink with storage and public folder

Hello, im uploading an File right now in my storage directory of the laravel app, then i wanna try to link these together but it is not working properly, its not creating an folder just an txt file. with an hash an the directory structure. ↓ right there is the storage file

XSym
0032
1332e1c21e71b0474d26fcc1174f20dd
/var/www/html/storage/app/public

Laravel version is 5.7 im not really familiar with that version till now im was just using the new ones. so there is also no links method in filesystems.php. My Code looks like this. ↓ right here to see

public function store(StoreRequest $request): Response
    {
        $request->validated();

        $code = new Code();
        $code->setUrl(trim(Input::get('url')))
            ->setDescription(Input::get('description'))
            ->setUserId(Auth::id())
            ->setSlug(Code::generateSlug());

        if ($request->file('logo')) {
            $extension = $request->file('logo')->getClientOriginalExtension();
            Storage::putFile('public', $request->file('logo'));
            $code->setLogo('bla'. '.' . $extension);
        }
        return $this->save($code);

if anybody could help, would really appreciate!

0 likes
2 replies
pt844931's avatar

@Tray2 Hey yes i have that, it was a problem on my side because the name i stored in the DB was an other which i saved in the programm. just a mistyping problem. realized it to late ^^

Please or to participate in this conversation.