Check URL for a folder
<p>How can I check the URL path for certain folders? I ask so that if we're in a certain folder, we can make a tab selected in the nav bar (just apply a style to that specific li). </p>

<p>So far I know</p>

<pre><code>$pagePath = $_SERVER['REQUEST_URI'];
</code></pre>

<p>So I can get a return that says something like <strong>/music/song/120/</strong> (or whatever it is). What kind of php function can I use that says </p>

<p>if <code>$pagePath</code> has "music", then do this. Meaning, if the path is <strong>/music/</strong> or <strong>/music/song</strong>, I should be able to </p>

<p>I plan on using this multiple times, </p>

<p>if <code>$pagePath</code> has downloads do this</p>

<p>if <code>$pathPath</code> has band do this</p>

<p>and so on. </p>

<p>Any suggestions?</p>
