a few changes to increase jQuery compatibility.
testing jquery compatibility of method val, text and html.