Author Topic: jQuery4 support with fixes !!! SERIOUS !!!  (Read 123 times)

jplevene

  • Pro Ultimate
  • Full Member
  • *
  • Posts: 210
    • View Profile
jQuery4 support with fixes !!! SERIOUS !!!
« on: January 20, 2026, 06:51:10 pm »
Another SERIOUS bug has appeared, however it wasn't an issue when v11.1.0 was released.

The newly released jQuery v4.0.0 has REMOVED the depricated $.trim(), $.isFunction() and $.isArray()

This means pqGrid does not work at all with the latest jQuery 4.0.0.

For anybody that needs a temporary fix, add the following after installing jQuery and before pqGrid:
Code: [Select]
// Make sure $.trim() exists
if(!jQuery.trim) {
jQuery.trim = function(text) {
return text == null ? "" : (text + "").trim();
};
}
// Make sure $.isArray() exists
if(!jQuery.isArray) {
jQuery.isArray = Array.isArray;
}
// Make sure $.isFunction() exists
if(!jQuery.isFunction) {
jQuery.isFunction = function(obj) {
        return typeof(obj)==="function";
    };
}