Then there must be another error or something is missing in your code.
cval would be undefined as well if this is all of your coding. Can you provide your running code (with the error) on jsbin, please?
Then there must be another error or something is missing in your code.
cval would be undefined as well if this is all of your coding. Can you provide your running code (with the error) on jsbin, please?