was using wrong syntax to get elements