title: Make the first sentence in each paragraph an <H3> by referencing two break tags and the next period, question mark, or exclamation mark
body: <p>I'm trying to insert an HTML tag after the first sentence in each paragraph of a given document.</p>
  
  <p>The code I came up with ( I am not a programmer) is working. </p>
  
  <p>The <code>$insert_pos</code> is the position where a tag was last inserted. It is needed because there is more than one paragraph in most of the documents. </p>
  
  <p>Now I need to also check for "?" (and possibly "!").</p>
  
  <pre><code>$insert_pos = strpos($content, ".", $insert_pos) + 1;
  $content= substr_replace( $content, "&lt;/tag&gt;", $insert_pos,0 );
  </code></pre>
  
  <p>Some context:</p>
  
  <p>Per CMS, a paragraph is generated with <code>&lt;/br&gt;&lt;br /&gt;</code>. So a document will have this format:</p>
  
  <pre><code> Lorem ipsum dolor sit amet, consetetur sadipscing elitr sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. &lt;/br&gt;&lt;br /&gt;Lorem ipsum. Lorem ipsum dolor sit amet, consetetur sadipscing elitr sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. &lt;/br&gt;&lt;br /&gt;voluptua.
  </code></pre>
  
  <p>I need each sentence in between <code>&lt;br /&gt;</code> and <code>.</code> OR <code>!</code> OR <code>?</code> to become the text inside of a <code>&lt;h3&gt;</code> tag. So in the format of <code>&lt;h3&gt;Lorem ipsum.&lt;/h3&gt;</code></p>