Find line which contains given word and return substring
<p>I have file with lines which look like  <strong>word_1:word_2</strong>
(for example file looks like </p>

<pre><code>username:test
password:test_pass
dir:root
</code></pre>

<p>)</p>

<p>. How to find from file word_2 when I have word_1 ? Is there in PHP contains and substring like in Java ?</p>
