$Muestra1 = $_GET['info1']; // ex. it gets " SI" $var1="_info1"; $contenido = substr_replace($var1, '$' . $Muestra1, 0, 0); echo $contenido; so my output is $SI_info1 instead of the content of the var $SI_info1 if I echo (line 4) echo $$contenido; i don't get anything if I echo (line 4) echo "$$contenido"; i get $$SI_info1 ------------- here it is again ---------- "; echo "want to print the variable that is on \$contenido: "; echo $SI_info1; ?> the output is $$SI_info1 ----------------------(hr)-------- the content of the variable SI_info1