I was wondering how to get the HTML of a panel AS WELL AS the input values from a panel? I can get the HTML like:
myPanel.getInnerHtmlElement().dom.innerHTML
But that only return me the HTML. For example if I have some HTML like below in Panel:
<input type="text" name="firstname">
And then enter a name in the text box, it should come back something like:
<input type="text" name="firstname" value="John">
instead I am getting back:
<input type="text" name="firstname">
Does anyone know how to get the HTML back with the input values as well? Thanks.
Modified the value attribute on the DOM whenever the value was changed:
$("input[type='text']").change(function () {
$(this).attr('value', $(this).val());
});
And then got the HTML when needed via:
myPanel.getInnerHtmlElement().dom.innerHTML