in reply to substitution of variable within a variable

You got your single and double quotes backwards.
Looks like you need to say:
$aword = 'foo'; # use single quotes instead of double $containmentvar = "$aword"; # use double quotes instead of single
Variables between double quotes will be interpolated to their values, but between single quotes they will be taken literally.

Hope this helps,
Jeff

UPDATE:
Hmm, when I first read your post, I thought you were wanting symbolic references - I have to agree with tilly on this one, and do read ar0n's link that he provided, but here you go anyways:

$aword = 'foo'; $containmentvar = 'aword'; # no dollar sign here $$containmentvar = 'bar'; # foo or bar? print "$aword\n";
Remember, you can't use strict with this code, that should be reason enough to find another solution, but if you aren't coding heart monitoring devices you should be ok.

Now that I have handed a loaded gun to somebody, I am going to find a lawyer.