• Resolved kisabelle


    Hi, we recently updated to WooCommerce 3.0 and are now getting a select2.js error coming from the WooCommerce Export Orders – PRO Plugin. This javascript error is appearing on the edit order page in the admin area, and is preventing us from being able to issue refunds via Stripe. We have had to disable the plugin for now.

    Here’s a sample console error:

    select2.js:934 Uncaught Error: Option ‘ajax’ is not allowed for Select2 when attached to a <select> element.
    at String.<anonymous> (select2.js:934)
    at Function.each (load-scripts.php?c=0&load[]=jquery-core,jquery-migrate,utils,jquery-ui-widget,jquery-ui-core,jquery…:2)
    at constructor.prepareOpts (select2.js:932)
    at constructor.prepareOpts (select2.js:2794)
    at constructor.init (select2.js:690)
    at HTMLSelectElement.<anonymous> (select2.js:3578)
    at Function.each (load-scripts.php?c=0&load[]=jquery-core,jquery-migrate,utils,jquery-ui-widget,jquery-ui-core,jquery…:2)
    at a.fn.init.each (load-scripts.php?c=0&load[]=jquery-core,jquery-migrate,utils,jquery-ui-widget,jquery-ui-core,jquery…:2)
    at a.fn.init.$.fn.select2 (select2.js:3565)
    at HTMLSelectElement.<anonymous> (wc-enhanced-select.min.js:1)
    (anonymous) @ select2.js:934
    each @ load-scripts.php?c=0&load[]=jquery-core,jquery-migrate,utils,jquery-ui-widget,jquery-ui-core,jquery…:2
    prepareOpts @ select2.js:932
    prepareOpts @ select2.js:2794
    init @ select2.js:690
    (anonymous) @ select2.js:3578

    Please advise when this issue is resolved. If you require additional information / logging info I’m happy to help.

    Thank you!

Viewing 15 replies - 1 through 15 (of 38 total)
  • i have similar problem, but i cant edit the products

    Yes, this should be fixed right away because it breaks functionality in Woocommerce 3. See: 3.0 error option ajax is not allowed for select2

    • This reply was modified 7 years, 2 months ago by Jamil Jonna.

    So WooCommerce make a change and say other plugins need to be disabled or updated? I can see its Advanced Custom Fields is causing the issue, which is a necessary plugin for the site to work.

    Thread Starter kisabelle


    In my case the console was indicating to me that the error came from the WooCommerce Export Orders – PRO Plugin.

    According to the info in the link posted by @jonna it looks like all plugins simply need to load Select2 v4 instead of Select2 v3, in order to be compatible with WooCommerce 3.0, so that means that ACF will need to provide an update as well. I do not have any ACF fields on my WooCommerce products / orders so in my case ACF doesn’t produce any error on WooCommerce related admin pages.

    It is unfortunate that WooCommerce is creating breaking changes like this with their updates.

    • This reply was modified 7 years, 2 months ago by kisabelle.


    I’m facing the same problem, is there any solution??
    My products variations are not showing up on single product pages.
    My clients can’t buy, I can’t sell, I’m loosing money and my website credibility is decreasing.

    Someone please help me!

    Thread Starter kisabelle


    @gustavoleal If it’s affecting the front-end of your website then it couldn’t be caused by this plugin, which only runs in the back end of the site.



    Hello Kisabelle!! Thanks for replying me, your help is very important to me!!
    I think it’s affecting the front-end because the error message told on this top topic is been showed on back-end. My products variations are gone from some products and when I try to open product attributes the attributes are gone and when I try to add some attribute the page enters on a loading loop.
    Then I open the browser inspect console (chrome) the message error is there, a lot of errors. That’s the message:
    Uncaught Error: Option ‘ajax’ is not allowed for Select2 when attached to a <select> element.
    at String.<anonymous>

    WooCommerce has some balls breaking other plugins and demanding they spend time and money updating to select3 4.x, JUST so their stuff works. That’s BAD practice guys Ever heard of a shim? No? Might want to. WooCommerce is not the be all end all plugin for which all others by submit to ro comply with. Damn shame. EDD, anyone?

    Plugin Author merlinmonmouth


    Hi all – sorry for the delay.

    Yes the latest WooCommerce upgrade has broken many plugins, this one included.

    We’re cooking up the fix and will get it out – appreciate everybody’s patience.



    I’m having this problem too with Woocommerce 3.0.3 and ACF Pro.

    Any idea when the fix will be ready ? Thanks 🙂


    ACF Pro should work fine with WC 3.0.3 and be able to use Select v4.


    Plugin Author merlinmonmouth



    We released a fix for WooCommerce 3.0 should be working – please let us know if you see any issues.

    too bad, the error is still there.
    I see the select2 error at the adding/editorng eleted products.
    as a programmer, I know that the newer select2 plugin isnt working anymore with <select> boxes, only with <input…

    • This reply was modified 7 years, 2 months ago by Dirk Zaal.

    Hola, tengo un error en Woocmmerce, no puedo seleccionar los atributos del producto y no se como solucionarlo, alguien puede ayudarme?, gracias.

Viewing 15 replies - 1 through 15 (of 38 total)
  • The topic ‘select2.js error after updating to WooCommerce 3.0’ is closed to new replies.