WordPress.org

Ready to get started?Download WordPress

Forums

Page Builder by SiteOrigin
[resolved] JS error on select menus & radio input difficulties (8 posts)

  1. PeterRKnight
    Member
    Posted 1 year ago #

    bug: changing an option on a select input on any widget in the widget admin produces a "Object *[] has no method 'apply'" error

    Using...
    vanilla install of WP 3.6, page builder 1.2.11, no other plugins installed, default theme.

    pick any widget that has a dropdown select option (custom menu widget for example), change the selection and the error is produced. I tried this in the Widget admin, haven't checked inside the post editor.

    Also, widgets with radio element options don't have their values populated and checked properly when used inside the page builder.

    http://wordpress.org/plugins/siteorigin-panels/

  2. PeterRKnight
    Member
    Posted 1 year ago #

    errors still present in 1.3
    Could you have a look at fixing /widgets/js/admin.js in your next release?

  3. Greg Priday
    Member
    Plugin Author

    Posted 1 year ago #

    Hey there Peter. I could be wrong, but I think I had a look at this issue when you posted it but I couldn't recreate it. I'll take a proper look for the next release, and possibly contact you for some more information.

    This should be fairly easy to fix.

  4. PeterRKnight
    Member
    Posted 1 year ago #

    Hi Greg,

    I thought it was on my end too at first, but I reproduced the error with a plain install, only pb installed and twentytwelve or twenty thirteen. I looked at admin.js inside the widgets folder and I don't think you meant to code this:

    $('body').on('change', function(){
        }, '*[]');

    Dequeueing this script solved the issue on my end.

    The radio button issue is due the way the code in panels.admin.panels.js tries to populate values in the input fields, it overwrites the different radio values. In addition to that it doesn't check the radio button. Your code does handle checkbox settings around line 198, shouldn't be hard to fix it for radio elements too.

  5. Greg Priday
    Member
    Plugin Author

    Posted 1 year ago #

    This is why we keep you around Peter. I completely missed that! That really wasn't meant to be there. I have a few more issues to fix before I release it, but this'll be sorted in 1.3.1.

    Thanks. Really appreciate it.

  6. PeterRKnight
    Member
    Posted 1 year ago #

    Great! glad that was helpful

  7. PeterRKnight
    Member
    Posted 11 months ago #

    Any chance a fix for radio input fields might make it in on a forthcoming release? A github to send patches to would also work nicely.

  8. Solinx
    Member
    Posted 10 months ago #

    Hi Greg,

    I suspect something similar is happening for select boxes with the 'multiple' parameter.

    The widget I wrote behaves as expected in a regular sidebar, but in the page builder the array is reduced to one selected option.

    Do you think it is related? And if so, do you have plans for fixing this issue?

    Regards,
    Wouter

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic