Multiple str_replace?
<p>I'm trying to replace a URL in CodeIgniter that has certain parameters.  Not that CI should matter at this point as I have the best part of it working.</p>

<p>Lets say my URL is :</p>

<pre><code>?device=field1-field2_field3+field4
</code></pre>

<p>By echoing out $devicelink2 that should show:</p>

<pre><code>field1 field2.field3*field4
</code></pre>

<p>Currently it works with everything but replacing the +.  For some reason it replaces + with a space.</p>

<p>However I can't get that working using the below code.  Any ideas?</p>

<pre><code>    $device = $this-&gt;input-&gt;get('device');
    $devicelink = str_replace("-"," ",$device);
    $devicelink1 = str_replace("_",".",$devicelink);
    $devicelink2 = str_replace("+","*",$devicelink1);
</code></pre>
