some quick help with this small piece of code
<p>How come when I echo $p, the variable which Im trying to fetch using this loop doesnt get displayed in the path.</p>

<pre><code>$name_image2="picture.jpg";
for ($i=2; $i&lt;=$nr_of_pics; $i++){
     $img='name_image'.$i;
</code></pre>

<p><code>echo $$img;</code> gives me this: '<code>picture.jpg</code>' which is correct.
but when echoing $p like this:</p>

<pre><code>   $p="/SV/main/temp_images/$$img"; echo $p;
</code></pre>

<p>I get this: <code>SV/main/temp_images/name_image2</code> --> the variable 'name_image2' doesnt get called here, why?
I want it to say: <code>SV/main/temp_images/picture.jpg</code></p>

<p>Thanks</p>
