When using the AdvAgg 7.x-2.36 module with Drupal 7 on a server with PHP8, an infinite loop occurs within the code within JShrink. The author of JShrink has an updated version 1.4.0 that fixes the issue but this version never made it into the module before Drupal 7's end of life. You can update the affected jshrink.inc file within sites/all/modules/advagg/advagg_js_compress with the updated version downloadable below. This will allow the module to work with PHP 8
Download and Install
Here we go:
- Download Drupal7-JShrink-PHP8Fix.zip to your system
- Extract the file jshrink.inc from the ZIP file
- Within your sites/all/modules/advagg/advagg_js_compress directory, rename jshrink.inc to jshrink.inc.old
- Copy the new jshrink.inc from the ZIP file to your sites/all/modules/advagg/advagg_js_compress directory
That should be it. Hope it helps you out!
Shoutout to Brandon Bergren with Tag1Consulting for figuring out the cause