Skip to content
● Grav 2.2 is out: 2x faster cold starts and 96% less memory on big sites. Read the announcement →

Server error Undefined array key 1

Solved by Natalia Bazilenco View solution

Started by Natalia Bazilenco 4 years ago · 1 replies · 594 views
4 years ago

Hello everyone, this is the second time this month that an error has appeared on my website:
Server Error
Sorry, something went terribly wrong!

0 - An exception has been thrown during the rendering of a template ("Undefined array key 1").
For further details please review your logs/ folder, or enable displaying of errors in your system configuration.

I'm using the Quark theme.

Plugins and system updated

What in logs ina admin panel:

CRITICAL An exception has been thrown during the rendering of a template ("Undefined array key 1").

In logs on hosting:

grav.CRITICAL: An exception has been thrown during the rendering of a template ("Undefined array key 1"). - Trace: #0 /vendor/twig/twig/src/Template.php(420): Twig\Template->displayWithErrorHandling(Array, Array) #1 /vendor/twig/twig/src/Environment.php(497) : eval()'d code(268): Twig\Template->display(Array) #2 /vendor/twig/twig/src/Template.php(214): TwigTemplate4119757e4b837b134251ac71bb4e36a01d4724759f2eedafd849fefef32419271225928728->block_item(Array, Array) #3

and etc
Any help please.

last edited 03/25/23 by Natalia Bazilenco
4 years ago Solution

The error was fixed by switching the version php. Was 7.3x Now enable 7.4x
Of course, it is not clear why the website stopped working with the minimum version. Before that everything was ok.

Suggested topics

Topic Participants Replies Views Activity
Support · by stell, 7 days ago
5 243 1 hour ago
Support · by gravinator, 1 month ago
5 458 3 hours ago
Support · by Gravver, 2 weeks ago
6 280 1 week ago
Support · by Marcel, 4 weeks ago
2 338 1 week ago
Support · by blu3prince, 2 weeks ago
1 255 2 weeks ago