Support the ongoing development of Laravel.io →
Laravel Blade Views
Last updated 1 year ago.
0

is that bladefile code above the user.productpage blade code?

can you try

return view('user.productpage', 
compact( 'post')
);
	
Last updated 5 years ago.
0

also, if you are using webpack, it uses scss and compiles to public / css /app.css if that is the case in your app make sure your blade file is loading the css <link href="{{ asset('css/app.css') }}" rel="stylesheet"> or better <link rel="stylesheet" href="{{ mix('/css/app.css') }}">

0

Hope this might work it out smoothly. As it is so hard to manage and control the controller, happy wheels free

0

This was a silly mistake i had done when referencing stylesheets,script files.I had referenced without specifying the resource directory.

<link href="css/styles.css" rel="stylesheet">

//rather

<link href="/css/styles.css" rel="stylesheet">

what this does is the browser tries to access the resources in

http://css/styles.css

but the resources are saved in the public folder so we should specify that css folder is a directory in the public folder so it would access

http://mysite.io/css/styles.css

most of the time this scenario works fine in the localhost but when you try emailing or upload to the server you get this tricky error.

0

Sign in to participate in this thread!

Eventy

Your banner here too?

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.