I have a button on a Webpage that needs to be pressed so that a data file can be rebuilt to then dowload this file. I don't know any HTML, so I am unsure which variables are needed to get the driver.find_element_by_xpath() to correctly locate the button on the Webpage
The HTML code of the website is the following:
<html><head><title>HPC Data Directory</title><META HTTP-EQUIV="refresh" CONTENT="60"><META HTTP-EQUIV="Pragma" CONTENT="no-cache"><META HTTP-EQUIV="Expires" CONTENT="-1"></head><body bgColor=#ffffff leftMargin=0 topMargin=10 marginwidth="0" marginheight="0"><div align=center style="width: 833; height: 470"><table style="border: 1px solid #000080" height=384 cellSpacing=0 cellPadding=0 width="815"><tbody><tr bgColor=#EEEEEE><td style="border-bottom: 1px solid #000080" vAlign=bottom noWrap height=70 margin=50 width="815"><h2 align="center"><font face="verdana" color="#006699">HPC Data Web Server</font></h2></td></tr><tr><td colSpan=5 height=380 width="815" vAlign=top background="llblue.jpg" style="background-repeat: repeat-y;"><div align=center><center><font face="verdana"><table width="90%" border=0 align=center><tbody><tr><td width="95%"><h2 align=center><br>Data File Directory</h2><table border=0 width=750><tr align=left bgcolor=#aaccff><th width=50%>File Name</th><th width=15%>Records</th></tr><td align=left><a href="/DATA.XLS" target="_blank">DATA.XLS</a></td><td align=left>10000</td><br><br></table><form name=form1 method=post><br><br><br><input type=hidden name=BuildFile value="Build"><br><p>Click link above to download data file.</p><input type=button name=Export value="Rebuild Data File" onclick="submit()"></form></td></tr></tbody></table></font></center></div></td></tr><tr><td colSpan=5 height=20 width="805" background="llblue.jpg" style="background-repeat: repeat-y;"></td></tr></tbody></table></div></body></html>
I gathered that the code for the button for "Rebuilding the Data", which needs to be done before each download, is this one:
<input type=button name=Export value="Rebuild Data File" onclick="submit()">
How do I properly format these variables into something that the driver.find_element_by_xpath() can use to locate and press the button? Is this even the xpath thing? Or should I be using another method to locate the button like css.