title: replace multiple Colors with transparent in an image
body: <p>i have a rain radar image here with big grey and white parts as backgroound. i need to remove the background ( grey / white ) and make in transparent. but it does not work. i already tried</p>
  
  <pre><code>   // replace white
     $rgb = imagecolorexact($im, 255, 255, 255);
     imagecolortransparent($im, $rgb);
     // replace grey
     $rgb = imagecolorexact($im, 189, 189, 189);
     imagecolortransparent($im, $rgb);
  </code></pre>
  
  <p>But this is not working. Its only one part transparent ( either the white one or the grey one ). I cannot remove both colors at the same time.</p>
  
  <p>I really have no idea how images work .. so please if you know a way to achieve what i want please let me know.</p>
  
  <p>Thanks</p>
  
  <p><a href="https://i.stack.imgur.com/b0Eqm.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/b0Eqm.png" alt="enter image description here"></a></p>