Possible Duplicate:
Possible to parse a HTML document and build a DOM tree(java)
Hi, We use to parse the xml using DOM, SAX or JDOM. Is there any way to parse the HTML file.
ex. : main_file.html
< div class="Main_Class" id = "main_id" style="width="100%;height="100%">
< div class="sub_class" **id = "sub_id_one"** style="width="50%;height="100%"> </div> < div class="sub_class" **id = "sub_id_two"** style="width="50%;height="100%"> </div>
< /div
file_two.html
< div style="position: relative; float: left; width: 24%; height: 100%;>
< input type="button" class="button" value="4"/>
< /div
I want to parse the main file, get the sub_id and then append the the file_two.html on the basis of relativ id.