I’m trying to create a dynamic sidebar that uses bootstrap 4 accordion with the widget’s title as the toggle link and the widget content as the accordion’s content:
I’m listing all sidebars like that:
When wordpress sidebar outputs any particular
registered sidebar it loop through all widgets that assigned through it and outputs it (i guess). Is is possible to hook into the loop and add some content, say I want to add a ad code every three widgets.