Get the correct attribute's value