print html code of selected elemnt selenium python code example Example: python selenium get html content element.get_attribute('innerHTML')