I have a configurable product with two dropdown attributes called “Option A” and “Option B”.
I have included a jQuery popup which contains an unordered list, which is populated with values from the first dropdown attribute.
When the user clicks on one of the images within the popup, which has a value that corresponds to the values within the first dropdown, that value is selected for the first dropdown; this is done using jQuery
$ j("#option_select > a").click(function(){ jQuery.noConflict(); var choice = $ j(this).attr('value'); $ j('#attribute160 option:contains('+choice+')').attr('selected','selected'); $ j('#swatch').attr('src', '+choice+'.jpeg'); $ j("#swatch").show(); $ j.magnificPopup.close(); $ j('#option_image_holder').text(choice); $ j('#option_name_p').text('Click Here To Change Your Choice'); });
The issue I have is the second dropdown attribute, “Option B”,isn’t populated using this technique for selecting an option for “Option A”.
How would I go about tirggering the event which populates the second dropdown attribute, which already happens when the user physically clicks on the dropdown and selects an option.
Thanks for any advice!