DV-JF Posted June 5 Share Posted June 5 Hey, I'm asking myself, what's the best way to filter a SelectableOptionArray for multiple Values. Is there a better way than doing it like this: if( $page->optionField->hasValue('foo') || $page->optionField->hasValue('bar') || $page->optionField->hasValue('buzz')) { echo $something }; Any ideas welcome! Greets! Link to comment Share on other sites More sharing options...
elabx Posted June 5 Share Posted June 5 Maybe you can do? $page->optionField->find("value=foo|bar|buzz") Not sure what's the property that actually holds the value ? Let me know if it actually works! lol Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now