should be $name  the { } around it is only required when its in a string.