title: Regex expression to match only html p tags or no tags
body: <p>I need a regex expression that matches only the first p tag (<code>/&lt;p&gt;(.*)&lt;\/p&gt;/</code>) or the first line that does not start with <code>&lt;</code> if it doesn't find a p tag before this. I tried this : <code>/(?!&lt;)(.*)||&lt;p&gt;(.*)&lt;\/p&gt;/</code> but then this selects the first line regardless of if there is a <code>&lt;</code> at the begging of the line.</p>
  
  <p>How can I make it only select the first line that starts with a p tag or without any tags.</p>
  
  <p>For example it should select <code>&lt;p&gt;Text&lt;/p&gt;</code> here:</p>
  
  <pre><code>&lt;h2&gt;Tittle&lt;/h2&gt;
  &lt;p&gt;Text&lt;/p&gt;
  </code></pre>
  
  <p>and Text here:</p>
  
  <pre><code>Text
  &lt;h2&gt;Title&lt;/h2&gt;
  &lt;p&gt;More text&lt;/p&gt;
  </code></pre>