Ok sorry I wasn’t very clear.
I have my database table that contains my navigation menu items.
So I added these as a repeater on my sidebar.
Below, we see the list of navigation items as per the database are showing fine.
They are showing fine because I have set the sidebar as a repeater container and on page enter I am setting data in the repeater to show the navigation items as seen below.
I wanted to loop over each item in the repeater to check the specific navigation item so that I can use Icon Logic to assign an icon to each item. As shown below.
So I first set a variable “navitem” equal to the data from the sidebar container that is a repeater.
Then I set the value of another variable “icon” based on the value of “navitem” which is set to the data from the sidebar repeater container.
So far I can only show the last item from my if else login above that is set the icon to “payments”.
as shown below.
That means I am not checking correctly for which data item is in the sidebar container.
I’m stuck here.