title: Replace multiple characters with multiple replacers
body: <p>I have many calls like this throughout the code, escaping any backticks on the columns of a row. </p>
  
  <pre><code>htmlentities(str_replace("`", "``", $row['column']), ENT_QUOTES);
  </code></pre>
  
  <p>I made an addition, requiring the column to replace a <code>#</code>width <code>##</code>. Since most of these calls happen inline an output, I would like to have a solution in a single line.</p>
  
  <p>I was thinking conditional regex (preg_replace_callback), but is this the best way to achieve that? So what I need is:
  replace backticks with 2 backticks, and replace hashes with 2 hashes. (This is for escaping purposes).</p>