PHP check string for html
<p><code>$content</code> gives the html code like:</p>

<pre><code>&lt;p&gt;text&lt;/p&gt;
&lt;p&gt;&lt;img ... /&gt;&lt;/p&gt;
&lt;div class="video"&gt;...&lt;/div&gt;
</code></pre>

<p>or just </p>

<pre><code>&lt;p&gt;text&lt;/p&gt;
&lt;p&gt;more text&lt;/p&gt;
</code></pre>

<p>Also we have a variable:</p>

<pre><code>$video_match = false;
</code></pre>

<p>We should turn <code>$video_match</code> to <code>true</code>, if <code>&lt;div class="video"&gt;</code> (exactly this code) exists in <code>$content</code>.</p>

<p>Thanks.</p>
