You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Renders two sections that both say "Variant Images."
The first contains the following error (because there not any fields associated with it):
Warning: Invalid argument supplied for foreach() in [[PATH]]/rapid-addon.php on line 425
Warning: Invalid argument supplied for foreach() in [PATH]]/rapid-addon.php on line 432
The second section renders correctly with the proper image settings as shown in the screenshot above.
To Solve
I have modified the code at line 420 to check if fields exist before adding the section, and this correct the issue i.e.:
However, if I am using the API incorrectly to add the images field, please let me know.
The text was updated successfully, but these errors were encountered:
philbirnie
changed the title
Unable to add a single import_images field.
Unable to add a single import_images field without AddOn creating two sections.
Mar 26, 2021
I understand the problem. I gave the same names the add-on and images section. So, this is expected behavior.
From the screenshots I see that first section - it's the add-on main section. It is named 'Variant Images' because it's how you named the add-on in this part:
$this->add_on = new RapidAddon( 'Variant Images', 'variant_gallery' );
The second section - it is images section and it is named 'Variant Images' because you gave it this name here:
Problem
I am unable to add a single Import Images field without the add-on creating an superfluous section above -- for example, this code:
Renders two sections that both say "Variant Images."
The first contains the following error (because there not any fields associated with it):
The second section renders correctly with the proper image settings as shown in the screenshot above.
To Solve
I have modified the code at line 420 to check if fields exist before adding the section, and this correct the issue i.e.:
However, if I am using the API incorrectly to add the images field, please let me know.
The text was updated successfully, but these errors were encountered: