I have single HTML form, but structured as multiple tab using display:none option.
And each tab has few section which will display block / none based on previous tab section.
I want to add print button in confirmation thank page which appear after form submission, that should print whole form (only with fields filled with value) in a same structure like HTML page.
<form>
<div id="section1">
<input type="text" id="name1">
<input type="text" id="name2" style="display: block;">
</div>
<div id="section2" style="display: block;">
</div>
<input type="submit">
</form>
I tried to use window print function, but that works only for current visible section.
This code was wrote long back without having this requirement in mind. so can some one suggestion some solution for this?