You are not logged in.

Announcement

 Téléchargez la dernière version stable de GLPI      -     Et vous, que pouvez vous faire pour le projet GLPI ? :  Contribuer
 Download last stable version of GLPI                      -     What can you do for GLPI ? :  Contribute

#1 2024-02-20 17:50:37

sIBajHYG
Member
From: Mission [KS]
Registered: 2023-08-18
Posts: 75

Bug after saving fields for the first time with the Additional Fields

Good morning. Please tell me I have Additional fields for Tickets. These are the types:
4q5AmB.jpg
After entering the data for the first time and clicking the "save" button, I get a redirect to a web page with an error.
wz9tWG.jpg
error text:

Uncaught Exception TypeError: stripslashes(): Argument #1 ($string) must be of type string, array given in /glpi_data/www/html/glpi/src/Log.php at line 251

oygIi0.jpg
All entered data is saved. Please tell me what I can try to do to fix this?

Last edited by sIBajHYG (2024-02-20 18:08:11)


Linux ubuntu-22.04.2-live-server-amd64, PHP 8.1.2, Apache 2.4.52, MariaDB 10.6.12, GLPI 10.0.15.
GLPI Inventory 1.3.5, PHP SAML 1.3.0,  Oauth IMAP 1.4.3, Additional Fields, 1.21.8,Ticket Cleaner.

Offline

#2 2024-02-21 02:22:23

cconard96
Moderator
Registered: 2018-07-31
Posts: 2,809
Website

Re: Bug after saving fields for the first time with the Additional Fields

Please check files/_log/php-errors.log for the full stack trace for the error (shows the the path the code took before it got to the line with the error).


GLPI Collaborator and Plugin Developer.
My non-English comments are automated translations. Sorry for any confusion that causes.
Mes commentaires non anglais sont des traductions automatiques. Désolé pour toute confusion qui cause.
Mis comentarios que no están en inglés son traducciones automáticas. Perdón por cualquier confusión que cause.

Offline

#3 2024-02-21 19:59:59

sIBajHYG
Member
From: Mission [KS]
Registered: 2023-08-18
Posts: 75

Re: Bug after saving fields for the first time with the Additional Fields

This?

[2024-02-19 11:54:56] glpiphplog.CRITICAL:   *** Uncaught Exception TypeError: stripslashes(): Argument #1 ($string) must be of type string, array given in /glpi_data/www/html/glpi/src/Log.php at line 251
  Backtrace :
  src/Log.php:251                                    stripslashes()
  plugins/fields/inc/container.class.php:1318        Log::history()
  plugins/fields/inc/container.class.php:1197        PluginFieldsContainer::constructHistory()
  plugins/fields/front/container.form.php:58         PluginFieldsContainer->updateFieldsValues()

Linux ubuntu-22.04.2-live-server-amd64, PHP 8.1.2, Apache 2.4.52, MariaDB 10.6.12, GLPI 10.0.15.
GLPI Inventory 1.3.5, PHP SAML 1.3.0,  Oauth IMAP 1.4.3, Additional Fields, 1.21.8,Ticket Cleaner.

Offline

#4 2024-02-22 19:59:12

sIBajHYG
Member
From: Mission [KS]
Registered: 2023-08-18
Posts: 75

Re: Bug after saving fields for the first time with the Additional Fields

Updated the "Additional Fields" plugin from 1.21.6 to 1.21.8, but this did not solve the problem


Linux ubuntu-22.04.2-live-server-amd64, PHP 8.1.2, Apache 2.4.52, MariaDB 10.6.12, GLPI 10.0.15.
GLPI Inventory 1.3.5, PHP SAML 1.3.0,  Oauth IMAP 1.4.3, Additional Fields, 1.21.8,Ticket Cleaner.

Offline

#5 2024-02-28 21:06:51

sIBajHYG
Member
From: Mission [KS]
Registered: 2023-08-18
Posts: 75

Re: Bug after saving fields for the first time with the Additional Fields

Experimentally we managed to find out that this bug occurs due to additional fields like “Rich text”. Filling these with text/code by default has no effect. The bug still appears. Only if you disable these 2 fields, the bug disappears. But I need fields like this...
9tr6lA.jpg
Please tell me what else I can try to do.


Linux ubuntu-22.04.2-live-server-amd64, PHP 8.1.2, Apache 2.4.52, MariaDB 10.6.12, GLPI 10.0.15.
GLPI Inventory 1.3.5, PHP SAML 1.3.0,  Oauth IMAP 1.4.3, Additional Fields, 1.21.8,Ticket Cleaner.

Offline

Board footer

Powered by FluxBB