WebsiteBaker Community Forum

WebsiteBaker Support (2.13.x) => General Help & Support => Topic started by: danville on April 22, 2022, 04:45:12 PM

Title: Twig Error with 2.13.1
Post by: danville on April 22, 2022, 04:45:12 PM
I am receive this error under Add-Ons and Access menus on the backend with a fresh install on Netfirms.com PHP 7.4

There was an uncatched exception
Call to undefined function Twig\ctype_alpha()
in line (469) of (/include/twig/twig/src/Lexer.php):

Also, pages and settings do not save.  I can eventually get settings or a page to save.  So, there is a weird problem with permissions.

PLEASE HELP!!
Title: Re: Twig Error with 2.13.1
Post by: crnogorac081 on April 22, 2022, 07:00:12 PM
Another question, can I use twig instead .htt files in backend template ?
Title: Re: Twig Error with 2.13.1
Post by: DarkViper on April 22, 2022, 08:46:01 PM
Yes/No  8-)
In order to use Twig templates instead of htt templates, the entire source code of the respective module or even core must be adapted. We are working on the next WB version. There will be many changes, some of them very far-reaching, in the next few months.
You can follow us there at http://project.WebsiteBaker.org.

Greatings, Manuela
Title: Re: Twig Error with 2.13.1
Post by: Luisehahne on April 22, 2022, 09:24:18 PM
I am receive this error under Add-Ons and Access menus on the backend with a fresh install on Netfirms.com PHP 7.4

There was an uncatched exception
Call to undefined function Twig\ctype_alpha()
in line (469) of (/include/twig/twig/src/Lexer.php):


We are able to fix it. It's not the WB Core, It's the twig class himself. We only have to know, which addon is throwing this exception, so we can test if it is solved.

Dietmar
Title: Re: Twig Error with 2.13.1
Post by: danville on April 22, 2022, 10:39:16 PM
No Addons - This is a fresh install from the 2.13.1 downloaded from WebsiteBaker.com
So, I am stuck.
Title: Re: Twig Error with 2.13.1
Post by: crnogorac081 on April 22, 2022, 10:47:35 PM
Quote from: DarkViper link=topic=32030.msg224121#msg224121
http://project.WebsiteBaker.org.

Greatings, Manuela
I would like to join, if it is possible.

Pm me login details
Title: Re: Twig Error with 2.13.1
Post by: Luisehahne on April 23, 2022, 10:33:53 AM
No Addons - This is a fresh install from the 2.13.1 downloaded from WebsiteBaker.com
So, I am stuck.

We created a ticket on Twig Github and got an answer in the morning. If we finished fixing the issue we inform you all and create a new patch.

Sorry for the circumstances, we hurry up

Dietmar

Title: Re: Twig Error with 2.13.1
Post by: Luisehahne on April 23, 2022, 05:22:12 PM
No Addons - This is a fresh install from the 2.13.1 downloaded from WebsiteBaker.com
So, I am stuck.

Seems that your provider disabled the Ctype Functions in php. We are working for  a solution, but it is not a quick patch possible. We need a few days. Maybe your provider again is willing to enable the Ctype Functions.

Dietmar
Title: Re: Twig Error with 2.13.1
Post by: Luisehahne on April 25, 2022, 03:43:10 PM
Please test the newest Patch 2.13.1.112 (https://addon.WebsiteBaker.org/pages/en/browse-add-ons.php?download=0099E945) and inform us the result, so we can close the error ticket on the project page

Dietmar
Title: Re: Twig Error with 2.13.1
Post by: danville on April 25, 2022, 07:26:39 PM
Unfortunately I do not have PHP 8.0.
Can the patch be configured to use PHP 7.4?
Title: Re: Twig Error with 2.13.1
Post by: hgs on April 26, 2022, 07:49:21 AM
Since this is a new installation with php 7.4.x, install the patch and report back to us if the error is gone.
Thanks
Postscript:
Just tested the patch on a test domain with php 7.4.x without problems
Title: Re: Twig Error with 2.13.1
Post by: danville on April 26, 2022, 10:36:07 AM
I installed the patch and this message shows up on the front and back ends.
"Composer detected issues in your platform: Your Composer dependencies require a PHP version ">= 8.0.0".

The composer files in WB root both include PHP 8.0.0

Not sure how to fix this.

I really appreciate any help I can get with this.
Title: Re: Twig Error with 2.13.1
Post by: hgs on April 26, 2022, 02:36:13 PM
The answer that gets to the root of the problem is in post #8 (https://forum.WebsiteBaker.org/index.php/topic,32030.msg224127.html#msg224127)
Title: Re: Twig Error with 2.13.1
Post by: danville on April 26, 2022, 03:38:02 PM
Post #8 states
"Please test the newest Patch 2.13.1.112 and inform us the result, so we can close the error ticket on the project page"

I informed the result as composer requiring PHP 8.0.0 as indicated in the two composer files in the WB root patch 2.13.1.112

I am unsure what you mean by "The answer that gets to the root of the problem is in post #8"

Is there a way to have the patch require PHP 7.4.x instead of PHP 8.0.x?

Thank you
Title: Re: Twig Error with 2.13.1
Post by: Luisehahne on April 26, 2022, 05:20:46 PM
Post #8 states
"Please test the newest Patch 2.13.1.112 and inform us the result, so we can close the error ticket on the project page"

I informed the result as composer requiring PHP 8.0.0 as indicated in the two composer files in the WB root patch 2.13.1.112

I am unsure what you mean by "The answer that gets to the root of the problem is in post #8"

Is there a way to have the patch require PHP 7.4.x instead of PHP 8.0.x?

Thank you

We are working that the patch require PHP 7.4.x and higher

Dietmar
Title: Re: Twig Error with 2.13.1
Post by: hgs on April 27, 2022, 07:48:48 AM
Post #8 states
"Please test the newest Patch 2.13.1.112 and inform us the result, so we can close the error ticket on the project page"

The patch 113 is ready for download (https://addon.WebsiteBaker.org/pages/en/browse-add-ons.php?download=0099E945), see here in the forum.
My site with php7.4 runs with it again.


To your comment:
...
here is the explanation what I meant:

#9 is
Quote
  Autor: Luisehahne « am: 25 April 2022, 15:43:10 » 
  • Zitat einfügen

 Please test the newest Patch 2.13.1.112 (https://addon.WebsiteBaker.org/pages/en/browse-add-ons.php?download=0099E945) and inform us the result, so we can close the error ticket on the project page

Dietmar
#8 is
Quote
  Autor: Luisehahne « am: 23 April 2022, 17:22:12 » 
  • Zitat einfügen

 Zitat von: danville am 22 April 2022, 22:39:16 (https://forum.WebsiteBaker.org/index.php/topic,32030.msg224123.html#msg224123)<blockquote>No Addons - This is a fresh install from the 2.13.1 downloaded from WebsiteBaker.com
So, I am stuck.
</blockquote>
Seems that your provider disabled the Ctype Functions in php. We are working for  a solution, but it is not a quick patch possible. We need a few days. Maybe your provider again is willing to enable the Ctype Functions.

Dietmar


But we hope that it will work with patch 113.
Title: Re: Twig Error with 2.13.1
Post by: danville on April 27, 2022, 11:37:42 AM
Thank you!!!!!  The 113 PHP 7.4 patch restores the Add-ons and Access menus and solves the Twig issue.

However, I am still having issues with saving files
   ". . . . Also, pages and settings do not save.  I can eventually get settings or a page to save.  So, there is a weird problem with permissions."

This is weird it is inconsistent, meaning that if I press save, eventually the same page will save.
This occurs both on a fresh install and upgrading sites. 
Is there a permissions utility for WB that can run a site-wide permissions check of files and folder?  Or is this something else?

Thank you!!
Title: Re: Twig Error with 2.13.1
Post by: hgs on April 27, 2022, 01:12:31 PM
For further analysis we need the access data from the superadmin (User-ID1) of the website and the FTP access data.
If you trust us, please send them by pm to Luisehahne
Title: Re: Twig Error with 2.13.1
Post by: danville on April 28, 2022, 05:18:09 PM
I sent my info to Luisehahne
Thank you for help with this!