title: Remove certain String from array php
body: <p>I want to get rid of that string with help of the <code>str_replace</code> function in <code>PHP</code> but I won't work. Can anybody help me?</p>
  
  <pre><code>$sql = "SELECT data from users";
    $result = $mysqli-&gt;query($sql);
    $widgets = [];
  while($row = mysqli_fetch_array($result))
  {
      $widgets[] = $row;
  }
  
  $alignment = explode("//",serialize($widgets));
  
  for($i = 0; $i&lt;count($alignment); $i++){
    str_replace("a:3:{i:0,:a:2:{:i:0;s:31;q}")
  }
  
    ?&gt;
  </code></pre>