Uploaded image for project: 'ZK'
  1. ZK
  2. ZK-4531

overridden jquery causes prime faces components to work incorrectly

XMLWordPrintable

      Steps to Reproduce

      1. if a framework loads a different version of jquery prior to ZK, then ZK overrides $ will cause the other framework to work incorrectly.
      Please refer to KEIKAI-220.

      Current Result

      • ZK always overrides $
      • ZK remove $.noConflict(). So users can't return control of $ back to the other framework.

      Expected Result

      ZK doesn't override $.

      Debug Information

      • in the previous version, zk jquery checks before overriding jQuery.
      • Previously, we customize jquery.js to avoid overriding $. * it's better not to fix this bug by modifying jquery itself because we might forget to migrate such customization in the future when upgrading jquery version. Like this time.
      • noGlobal is an internal parameter, we can't set it from outside
      • if zk sometimes overrides $ and sometimes doesn't, then it's risky that zk widgets use $. ZK widgets should all use jq since $ might reference to another version of jquery.

      Workaround

      apply jquery.src.js
      But this js workaround only works for Keikai 5.1.1 and will fail a zul page, so users can only load a JSF page. Besides, It doesn't work for keikai 5.2.0 for it registers functions on jQuery.

            Leon03 Leon03
            hawk hawk
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 2 hours
                2h
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 10 minutes Time Not Required
                10m