This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.

Jens Van Den Bossche
Jens Van Den Bossche

Hey,

Out of the blue I alway get an internal server error 500 when I save my layout. My layout still saves, but I always get the popup. Cant find anything about it.

I remade a layout file, same problem... I dont have it when I save other files.

daftspunky
daftspunky

Not enough information to help, sounds like a permission or write problem though. Check the web server log files to see the underlying error behind 500.

Jens Van Den Bossche
Jens Van Den Bossche

Sorry,

[29-Apr-2016 06:53:39 UTC] PHP Fatal error: Uncaught exception 'ErrorException' with message 'Undefined index: DB_DATABASE' in C:\xampp\htdocs\project\octobercms 2.0\config\database.php:59

I use a .env file for my DB config. This works everywhere but when I save a layout I get this error.

First it was this one.

[29-Apr-2016 06:49:05 UTC] PHP Fatal error: Uncaught exception 'ErrorException' with message 'Undefined index: DB_HOST' in C:\xampp\htdocs\project\octobercms 2.0\config\database.php:57

But then I removed the variable and set my host hardcoded in the config. But now he errors on the second rule. Sorry for my english. Could this be a bug? I can save partials, pages etc without any problem. Its only the layouts.

Jens Van Den Bossche
Jens Van Den Bossche

Tested a bit further.

If I dont use the .env I have no troubles.

Jens Van Den Bossche
Jens Van Den Bossche

Solved it.

I used the basic php $_ENV["..."] this does not always work apperently. using the helpen env() instead fixes the problems.

1-5 of 5

You cannot edit posts or make replies: the forum has moved to talk.octobercms.com.