title: str_replace for shortcode purposes
body: <p>Not really sure how to describe this, but I'll try my best. I'm trying to replicate a shortcode like structure for replacing a string within a certain container of text. Kind of like how Wordpress operates shortcodes.</p>
  
  <p>For example <code>[text str="hello world" class="text"]</code> would output as <code>&lt;p class="text"&gt;hello world&lt;/p&gt;</code>.</p>
  
  <p>Here's what I have so far with my exploration,</p>
  
  <pre><code>&lt;?php
  
  $text = "[hello]";
  
  $String = str_replace(array('[hello]'),array('Hi there!'),$text);
  echo $String;
  
  ?&gt;
  </code></pre>
  
  <p>I'm replacing text based on a specific string. How could I be more specific and call upon something like <code>[text str="hello world" class="text"]</code> and have it output like this <code>&lt;p class="text"&gt;hello world&lt;/p&gt;</code>?</p>