News:

Looking for documentation? Take a look on our wiki

Main Menu

Virtuemart.updateChosenDropdownLayout error

Started by 2dmaster, July 04, 2018, 22:12:58 PM

Previous topic - Next topic

2dmaster

this is not good function pls fix it !!!

VM8129:6 Uncaught TypeError: jQuery(...).chosen is not a function
    at Object.Virtuemart.updateChosenDropdownLayout (eval at <anonymous> (jquery.min.js:3), <anonymous>:6:35)
    at HTMLDocument.eval (eval at <anonymous> (jquery.min.js:3), <anonymous>:10:14)
    at c (jquery.min.js:3)
    at Object.add [as done] (jquery.min.js:3)
    at a.fn.init.ready (jquery.min.js:3)
    at eval (eval at <anonymous> (jquery.min.js:3), <anonymous>:9:19)
    at eval (<anonymous>)
    at jquery.min.js:3
    at Function.globalEval (jquery.min.js:3)
    at a.fn.init.domManip (jquery.min.js:4)



!!! worked if i set off in virtuemart cfg dropdowns regions and disable other vm libs !!!

Studio 42

Yes, i have same problem.
This is since last releases.
With a light code change, you solve the problem
in JOOMLAROOT/administrator/components/com_virtuemart/helpers/vmjsapi.php
after
Virtuemart.updateChosenDropdownLayout = function() {
add
if( typeof jQuery.chosen === "undefined") return;

It's not heavy tested, but the problem is most case because all Virtuemart changes and template, it's sometime a nightmare when you need to customize the javascripts for a shop

stawebnice

great thanks, that's exactly what I needed when multivariant select of product variant was not working :)

Milbo

But it must be something in your template, because the problem is rare. Furthermore the last version is already some months old.
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

Studio 42

Quote from: Milbo on August 10, 2018, 10:19:32 AM
But it must be something in your template, because the problem is rare. Furthermore the last version is already some months old.

I had already the problem, when you install a template demo pack, sometime they disable or do not load VM scripts because they use own select list javascript in product.