27 lines
493 B
Python
27 lines
493 B
Python
|
def get_template(html):
|
||
|
template = '''<!DOCTYPE HTML>
|
||
|
<html>
|
||
|
<head>
|
||
|
<meta charset="utf-8">
|
||
|
<link rel="stylesheet" href="stylesheet.css">
|
||
|
<title>Data Workers</title>
|
||
|
</head>
|
||
|
<body>
|
||
|
<div id="wrapper">{}</div>
|
||
|
</body>
|
||
|
</html>
|
||
|
'''.format(html)
|
||
|
return template
|
||
|
|
||
|
|
||
|
def write_html(html, filename):
|
||
|
html_template = get_template(html)
|
||
|
out = open(filename, 'w+')
|
||
|
out.write(html_template)
|
||
|
out.close()
|
||
|
|
||
|
print('*html file written*')
|
||
|
|
||
|
# html = ''
|
||
|
# write_html(html, 'data-workers.html')
|