S
S
sorry_i_noob2018-12-24 17:15:09
Laravel
sorry_i_noob, 2018-12-24 17:15:09

I downloaded the project on Laravel. My css folder is searched for in the root of the project. And it should be searched in the public folder. How can I set it to be searched in public?

Hello. I downloaded the Laravel site: https://github.com/jcc/blog . I deployed it myself. It started up for me, but without front-end. I looked in the console in chrome. And I saw that the browser is looking for styles in the root of the project. Whereas the CSS folder is in the public folder.
I am attaching a screenshot. The mouse cursor is not visible in the screenshot, but I hovered over "home.css:1" and I got a title about where the file is looking for.
5c20e880cfa67321007620.png
Why is my home.css file being searched for in the root, and for the developer - in the public folder (no wonder he put it there)? I didn't change the code. And how can I make sure that my files are also searched in the public folder?
PS There is no css folder on the github at all (and the home.css file too). But if you install the project according to the instructions that are indicated on the page on the github (the link to which I wrote above), then the css folder will be in the public folder.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexey Sklyarov, 2018-12-24
@sorry_i_noob

Because you need to assign the domain folder not /, but /public/. For example, when using Open Server, you need to go to Settings - Domains, add a new domain, for example: laravel.test1.ru (all files are in it), and assign laravel.test1.ru/public as the domain folder and start the server itself.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question