My situation is, I have a fully dynamic site, with a swiper, the slide needs to be controlled by a bunch of sub navigation, because some things are in different conditional areas I can not target the swiper from my submenus with swiper1.slideTo(1)
.
instead I need to use something like content.db_repeat_containers.items[3].cond_swiper.swiper.slideTo(1)
which works great as long as the swiper is always in position 4 of my repeat, or $key[3]
So I am thinking, is there any way I can use a where
to identify the $key
?
I have tried a few but can not seem to get the correct syntax for it, just using to console to figure out how to target this thing
dmx.parse("content.db_repeat_containers.items.values($key.where(`a_db_column`, 'isswiper', '=='))")
So in my database I stuck a column extra for this, and in the value of that i set it to isswiper
and its the only one with a value at all, so I am hoping I can find th correct value of $key by searching through it.
Sounds easy enough in my head.
Oh and by the way, Merry Christmas
Last updated: