Java Script Error Ninja Forms




Wordpress LScache Plugin: Java Script Error Ninja Forms

Last Updated on: Wed, 15 Apr 2026 00:00:02
We are having issues with a Ninja forms form displaying on our website that weve identified is related to Litespeed Plugin (when we deactivate it, as weve had to for now, the issue goes away). The form basically doesnt load and the space it should be in just appears blank. Even with all minifying and combining settings OFF and after clearing the cache, the issue persists. However, if Litespeed is deactivated, it works immediately. If litespeed is reactivated, the issue does not occur for a short while, but then appears after an indeterminate period of time (sometimes a day or two, sometimes an hour), the form disappears again and the following errors occur in the console. We have capture the following error in the dev console when the form doesnt work display: Uncaught constructor message: An el undefined must exist in DOM name: Error stack: Error: An el undefined must exist in DOM? at constructor._ensureElement (https://www.wmfs.net/wp-content/litespeed/cssjs/8660e.js?81934:8:13149)? at constructor.show (https://www.wmfs.net/wp-content/litespeed/cssjs/8660e.js?81934:8:11673)? at n.initialize (https://www.wmfs.net/wp-content/plugins/ninja-forms/assets/js/min/front-end.js?ver=3.5.1:5766:20)? at n.h.View (https://www.wmfs.net/wp-content/litespeed/cssjs/b59cd.js?1ca20:2:14148)? at n.constructor (https://www.wmfs.net/wp-content/litespeed/cssjs/8660e.js?81934:8:17520)? at n.constructor (https://www.wmfs.net/wp-content/litespeed/cssjs/8660e.js?81934:8:22127)? at n.constructor (https://www.wmfs.net/wp-content/litespeed/cssjs/8660e.js?81934:8:33576)? at new n (https://www.wmfs.net/wp-content/litespeed/cssjs/b59cd.js?1ca20:2:23460)? at https://www.wmfs.net/wp-content/plugins/ninja-forms/assets/js/min/front-end.js?ver=3.5.1:5972:23? at Function.v.each.v.forEach (https://www.wmfs.net/wp-content/litespeed/cssjs/8878d.js?1c669:2:1685) __proto__: Error captureStackTrace: ? () constructor: ? (t,e) toString: ? () urlRoot: http://marionettejs.com/docs/v2.4.2/ __proto__: Object We would be grateful for any assistance you can provide in resolving this, as we understand Ninja forms is official supported by your plugin. We have disabled litespeed for now as the site is live so we cant have our forms not working. Many thanks This topic was modified 1 year, 8 months ago by jamesround86. This topic was modified 1 year, 8 months ago by Jan Dembowski. The page I need help with: https://www.wmfs.net/the-hub/ Hi, Even with all minifying and combining settings OFF and after clearing the cache, the issue persists. However, if Litespeed is deactivated, it works immediately. could you please try reset to default setting , and see if it works ? Best regards, Hi there, I have reset the settings as youve suggested and will continue to monitor. As the issue doesnt appear immediately, Ill need to wait a day or two to see if the problem persists. Ill update the thread once Ive been able to check this. Thank you Update ? The issue has actually occurred almost immediately. The issue doesnt occur when viewed as a logged in admin user. But if the page is viewed as a new user (incognito window) the issue persists. The forms fail to load and the following error occurs in the dev console. Uncaught constructor message: An el undefined must exist in DOM name: Error stack: Error: An el undefined must exist in DOM? at constructor._ensureElement (https://www.wmfs.net/wp-content/plugins/ninja-forms/assets/js/min/front-end-deps.js?ver=3.5.1:20:13149)? at constructor.show (https://www.wmfs.net/wp-content/plugins/ninja-forms/assets/js/min/front-end-deps.js?ver=3.5.1:20:11673)? at n.initialize (https://www.wmfs.net/wp-content/plugins/ninja-forms/assets/js/min/front-end.js?ver=3.5.1:5766:20)? at n.h.View (https://www.wmfs.net/wp-includes/js/backbone.min.js?ver=1.4.0:2:14146)? at n.constructor (https://www.wmfs.net/wp-content/plugins/ninja-forms/assets/js/min/front-end-deps.js?ver=3.5.1:20:17520)? at n.constructor (https://www.wmfs.net/wp-content/plugins/ninja-forms/assets/js/min/front-end-deps.js?ver=3.5.1:20:22127)? at n.constructor (https://www.wmfs.net/wp-content/plugins/ninja-forms/assets/js/min/front-end-deps.js?ver=3.5.1:21:1423)? at new n (https://www.wmfs.net/wp-includes/js/backbone.min.js?ver=1.4.0:2:23456)? at https://www.wmfs.net/wp-content/plugins/ninja-forms/assets/js/min/front-end.js?ver=3.5.1:5972:23? at Function.v.each.v.forEach (https://www.wmfs.net/wp-includes/js/underscore.min.js?ver=1.8.3:2:1685) __proto__: Error captureStackTrace: ? () constructor: ? (t,e) toString: ? () urlRoot: http://marionettejs.com/docs/v2.4.2/ __proto__: Object I would appreciate any assistance you can offer to rectify this. I have once again deactivated Litespeed so that our users dont experience the issue. Thank you. Hi, Could you please explain me a bit for how can I reproduce this issue ? 1. install a WP 2. install https://wordpress.org/plugins/ninja-forms/ 3. install LSCWP 4. enable these 2 plugins 5. set up a form in a page 6. the issue happens by then ? Best regards, Hi there, Essentially yes. Although we have several Ninja Forms Add-ons also on the site. We use the Salient theme. We have carried out testing by disabling all plugins except the Ninja forms add-ons and Litespeed cache and the issue does persist. I can activate Litespeed for a short time to allow you to see the issue on our site, but we would obviously have to co-ordinate this to ensure that its online for as little time as possible due to the disruption of not having our forms working on our customers. Many thanks Hi, Please join our Slack if youd join in , please let me know your username so I will contact you , or you can reach me , with same username here. Best regards, Hi there, Unfortunately, while I do have a created Slack account Im unable to join via the link youve shared above. Receiving a variety of errors from it expecting me to have a @litespeedtech.com email address to a URI mismatch when I try to sign in to my existing Google based account. Can you please advise if there is an alternative way we can do this? Many thanks Hi, May I know your e-mail ? I can send you an invitation Best regards, Hi, invitation sent. Best regards, Thank you. Ive accepted the invitation and will message on there. Would love to know what worked. Same issue on Cloudways with Breeze caching plugin. Theme Flatsome. FIXED I disabled Breezes Lazy-Load images feature and the form is working again. All other minification and grouping options are active. Reason: solved issue Just for reference, I was having a similar issue in that the backend editing was throwing the same JS console error. The form on the front would load, but the CAPTCHA was not loading and not allowing the form to submit. I found that Ninja Forms was conflicting with Yoast SEO for some reason. As soon as I deactivated Yoast, I was able to edit the form and process a submission. Hope this helps someone.



LiteCache Rush: Speed comes from using less, not from doing it faster



Reference