What if I needed more than one hyperlink. Just one after another, each on a new line. I'm getting "positional argument follows keyword argument".
out = open("index.html", "w")
out.write(page.format(
heading = "<h1>Road Fatalities in Australia</h1>",
contents1 = "<p>On this site you will find road fatality statistical data.</p>",
contents2 = "<p>...</p>",
contents3 = "<p>...</p>",
link = '<a href="fatalities_per_year.html">A Look at Death Rates Over the Years</a>',
'<a href="fatalities_per_state.html">Which State has the Highest Fatality Rate?</a>',
'<a href="fatalities_per_day.html">Which Day of the Week is Deadliest?</a>',
'<a href="fatalities_per_time.html">Which Time of Day is the Deadliest?</a>',
'<a href="fatalities_trucks.html">How Many Trucks are in Fatal Crashes</a>',
'<a href="fatalities_speed_zones.html">Which Speed Zones are the Deadliest?</a>',
'<a href="fatalities_gender.html">Does Your Gender Increase the Risk of Dying?</a>',
'<a href="fatalities_age.html">Does Your Age Have Anything to do With Death-rates?</a>',
'<a href="fatalities_user.html">Fatality Data</a>'))
out.close()
I have also tried this:
out = open("index.html", "w")
out.write(page.format(
heading = "<h1>Road Fatalities in Australia</h1>",
contents1 = "<p>On this site you will find road fatality statistical data.</p>",
contents2 = "<p>...</p>",
contents3 = "<p>...</p>",
link = '<ul>
<li><a href="fatalities_per_year.html">A Look at Death Rates Over the Years</a></li>
<li><a href="fatalities_per_state.html">Which State has the Highest Fatality Rate?</a></li>
<li><a href="fatalities_per_day.html">Which Day of the Week is Deadliest?</a></li>
<li><a href="fatalities_per_time.html">Which Time of Day is the Deadliest?</a></li>
<li><a href="fatalities_trucks.html">How Many Trucks are in Fatal Crashes</a></li>
<li><a href="fatalities_speed_zones.html">Which Speed Zones are the Deadliest?</a></li>
<li><a href="fatalities_gender.html">Does Your Gender Increase the Risk of Dying?</a></li>
<li><a href="fatalities_age.html">Does Your Age Have Anything to do With Death-rates?</a></li>
<li><a href="fatalities_user.html">Fatality Data</a></li>
</ul>'
out.close()
I just need the links in a list, one after another. Nothing special, like follows:
A look at Death Rates Over the Years
Which State has the Highest Fatality Rate?
...etc...
Thanks in advance