title: php regex replace each character with asterisk
body: <p>I am trying to something like this.</p>
  
  <p>Hiding users except for first 3 characters.</p>
  
  <p>EX) </p>
  
  <ul>
  <li>apple -> app** </li>
  <li>google -> goo*** </li>
  <li>abc12345 ->abc*****</li>
  </ul>
  
  <p>I am currently using php like this:</p>
  
  <pre><code>$string = "abcd1234";
  $regex = '/(?&lt;=^(.{3}))(.*)$/';
  $replacement = '*';
  $changed = preg_replace($regex,$replacement,$string);
  echo $changed;
  </code></pre>
  
  <p>and the result be like:</p>
  
  <pre><code>abc*
  </code></pre>
  
  <p>But I want to make a replacement to every single character except for first 3 - like:</p>
  
  <pre><code>abc*****
  </code></pre>
  
  <p>How should I do?</p>