<p>That <code>contains</code> test just does a smple string comparison. Try this:</p>

<pre><code>{% if entry.pageOptions.contains('anotheroption')
     or entry.pageOptions.contains('testimonials') %}
</code></pre>

CC BY-SA 3.0
2015-05-09T22:44:55.660Z
That worked beautifully - so simple. Thank you!
glider
CC BY-SA 3.0
2015-05-09T22:00:40.910Z
2015-05-09T22:00:40.910Z
Marion Newlevant
<p>I have a set of checkboxes to show content on a page. I have one instance where I'd like to show something if either checkboxes are selected. I have searched around but couldn't find how to combine multiple value. Here's what I have now</p>

<pre><code>{% if entry.pageOptions.contains('testimonials') %} 
</code></pre>

<p>And I want it to be something like:</p>

<pre><code>{% if entry.pageOptions.contains('anotheroption|testimonials') %} 
</code></pre>

<checkboxes>
Multiple checkbox conditional
# Multiple checkbox conditional

(Asked by: username_0 on 2015-05-09)

I have a set of checkboxes to show content on a page. I have one instance where I'd like to show something if either checkboxes are selected. I have searched around but couldn't find how to combine multiple value. Here's what I have now
{% if entry.pageOptions.contains('testimonials') %} 

And I want it to be something like:
{% if entry.pageOptions.contains('anotheroption|testimonials') %}

**Tags:** checkboxes


---

## 1 answers

### Answer by username_1 on 2015-05-09. Score: 5 | Accepted answer

That contains test just does a smple string comparison. Try this:
{% if entry.pageOptions.contains('anotheroption')
     or entry.pageOptions.contains('testimonials') %}

> **Comments:**
> **username_0**: That worked beautifully - so simple. Thank you!  

---

