Looking for a string in PHP using strpos
<p>I'm trying to find a string inside of another string (I tried using strpos, but did not get any results back) using PHP. Here's what I've tried:</p>

<pre><code>$assignedBuildings = " , building 1, building 2, building 3";
$buildingName = "building 1";
$assArray = array_map('trim', explode(',', $assignedBuildings));
print_r($assArray);
echo("Looking for: " . $buildingName . " in " . $assignedBuildings);
$pos = in_array($buildingName, $assArray);
</code></pre>

<p>the print_r gets me this:</p>

<pre><code>Array
(
    [0] =&gt; 
    [1] =&gt; Test Chapter
    [2] =&gt; Test 2 Chapter
    [3] =&gt; Test 3 Chapter
)
</code></pre>

<p>and when I echo $pos, I get nothing (as in "").</p>

<p>Let's pretend $buildingName is "Test 3 Chapter". How would I find it in $assArray?</p>
