title: How to exclude a line break from regex character class?
body: <p>Given this PCRE pattern:</p>
  
  <pre><code>/(&lt;name&gt;[^&lt;&gt;]*&lt;\/name&gt;[^&lt;&gt;]*&lt;phone&gt;[^&lt;&gt;]*&lt;\/phone&gt;)/
  </code></pre>
  
  <p>And this subject text:</p>
  
  <pre><code>&lt;name&gt;John Stevens&lt;/name&gt;  &lt;phone&gt;888-555-1212&lt;/phone&gt;
  &lt;name&gt;Peter Wilson&lt;/name&gt;  
  &lt;phone&gt;888-555-2424&lt;/phone&gt;
  </code></pre>
  
  <p>How can I get the Regular Expression to match the first name-phone pair but not the second?  I don't want to match pairs that are separated by line breaks.  I tried including an end-of-line in the negated character class like so <code>[^&lt;&gt;$]*</code> but nothing changed.</p>
  
  <p>You can use the following online tools to test your expressions:<br>
  <a href="http://rubular.com/" rel="nofollow">http://rubular.com/</a><br>
  <a href="http://www.regextester.com/" rel="nofollow">http://www.regextester.com/</a><br>
  Thank you.</p>