2016-12-25 95 views

回答

4

你可以做这样的事情:

from IPython.core.display import HTML 

a = HTML('<a href="http://example.com">LINK TO THE WEB PAGE</a>') 
html = a.data 
with open('html_file.html', 'w') as f: 
    f.write(html)