mkucej / i-librarian-free

I, Librarian - open-source version of a PDF managing SaaS.
https://i-librarian.net
GNU General Public License v3.0
237 stars 28 forks source link

Creation of notes does not work for entries (PHP 8.3.6) #98

Closed KiralyCraft closed 1 month ago

KiralyCraft commented 4 months ago

I'm trying to add notes to an article on a system with Apache, php-fpm and PHP 8.3.6

It seems to give this error, and no notes are saved:

E_DEPRECATED: Creation of dynamic property HTMLPurifier_Lexer_DOMLex::$_entity_parser is deprecated

I'm currently at commit f94037241c1827a1b6ac8c555edd09f367032d3b

KiralyCraft commented 4 months ago

I seem to have fixed it. I downloaded version 0.14.15 of HTMLPurifier from here, and replaced the contents of i-librarian-free/classes/libraries/htmlpurifier with the contents of the library folder from the archive.

I only used the HTMLPurifier folder, the HTMLPurifier.php file and the HTMLPurifier.includes.php file. I renamed HTMLPurifier.php to something_else.php, renamed HTMLPurifier.includes.php to htmlpurifier.php and then edited it to require 'something_else.php' instead of require 'HTMLPurifier.php.

It seems to save notes correctly now.

I will create a PR, should I find the time. Thank you for this amazing piece of software.

kjnelan commented 2 months ago

I made the changes you suggested, and they worked brilliantly. Thank you for posting your process.

mkucej commented 1 month ago

TODO: Upgrade HTMLPurifier.

mkucej commented 1 month ago

fixed in 5.11.1