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

Can you share the code in your controller and view? You might want to use the pastebin.

Last updated 9 years ago.
0

Controller's code: http://laravel.io/bin/xKQnP

View's code: {{ Contact page }}

Route's code: Route::get('contact', 'WelcomeController@contact');

Thanks a lot. I'm stuck here and i really want to find a solution to this in order to use the blade templating.

Last updated 9 years ago.
0

Your controller is not sending any data to the page which means you can use your normal html in that page. ie, the original welcome template. Is your contact.blade.php located with in the pages directory that is located within the resources directory?

resourece --pages -- -- contact.blade.php

0

This is just a simple test page in order to see if it's working or not. I know i can use normal html and php but i would like to use the blade templating. Yes contact.blade.php is with in views/pages directory.

Is it possible the .htaccess, to cause this behavior? I'm not an .htaccess expert that's why i'm asking. Because when i'm loading the login page a css file also is missing.

0

first of all you should set your debuggig to TRUE

Next, if passing just a string (for whatever reason, since, as illuminate already mentioned, you can/should use pur HTML for doing this), you have to set the string within paranthesis:

View's code:

{{ 'Contact page' }}

That way it's working

0

My debugging is already set to true in the .env file.
APP_DEBUG=true

And the problem is still the same even if i remove the {{ }} from the contact page and have only string. If the name of the file is contact.blade.php is not working. In order to view the content of the contact page without getting a 500 Internal Server Error i have to name it contact.php.

0

with debug = true you should get some (more) info. maybe you have to take a look in your log file(s) as well.

with the data you provided above, it's working. i.e. the problem has to be somewhere else in your app.

did you add the Html Service Provider and the Html Facade aliases in your config/app.php ?

0

Yes it's working but only when is contact.php and not contact.blade.php. This is a fresh installation of laravel and the only thing i've changed was to add a new route, a new method in the controller and the new contact blade file with the text Contact Page. I do not think that blade engine require's the Html Service Provider and Html Facade to work. But anw i test it now with the 'Illuminate\Html\HtmlServiceProvider' and 'Html' => 'Illuminate\Html\HtmlFacade' aliases and still nothing.

Maybe something went wrong during installation. I will install a fresh laravel and try again.

0

new installation sounds like a good plan.

0

I have exactly the same issue! Recent installation of Laravel 5. No problems with basic welcome blade view. Today I added a test route to the login view and a test.blade.php view. Also changed the .env file to point at my local database.

All seemed fine and the route to the login view worked. I added some test routes and a few minor changes in the login view.

Now I cant see welcome or login or test views? However if I remove 'blade' from my test view name then it starts to work again??

Bit weird...

0

Ok I just made a completely fresh install of Laravel 5.

I Didn't change any files at all. When I open the site in my browser i get a blank page. If i change welcome.blade.php to welcome.php i then get the welcome view.

Is there a blade issue? Or am i doing something stupid here??

0

ok looks like its the good old Storage permissions thing again!... Gets me every time that one. I changed permissions on the storage folder and everything beneath to have write permissions for everyone and it now seems to work!

Anyway the permissions were correct with my first installation so I will carry on with this new installation and see if the blade issues happen again.

Last updated 9 years ago.
0

Finally. Fresh installation worked. Also emotec please make sure you give full permission (777) to the storage folder and all the subfolders.

Thank you guys for your time and support

0

Hi,

I have the same problem and I gave full permission to storage folder. Blade doesn't work. I don't know what can I do.

Help please

0

Can you share your code here ? Also you using a production or a testing environment?

0

serrano1004 said:

Hi,

I have the same problem and I gave full permission to storage folder. Blade doesn't work. I don't know what can I do.

Help please

I had this problem too and by changing resources folder permission every things is fine now

chmod -R 775 /var/www/laravel/resources/

Last updated 8 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

leman85 leman85 Joined 8 Feb 2015

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.