Reputation: 5
I am using HTML to create a basic webpage and would like to run one of my python programs on it, is this possible?
Upvotes: 1
Views: 96
Reputation: 18906
An alternative:
Take a look at the flask library if you want to create websites and run code from it: http://flask.pocoo.org
Upvotes: 2
Reputation: 5324
this is how you can use python for loop, using same way you can also import libraries
<table border=1>
<tr>
<th>Number</th>
<th>Square</th>
</tr>
<% for i in range(10): %>
<tr>
<td><% print i %></td>
<td><% print i**2 %></td>
</tr>
<% end %>
</table>
Upvotes: 1