Code: Alles auswählen
for result in cursor:
if result[1] == 0:
print >>handle_2, '<span class="no">' + result[0] + '</span>' + ' ',
elif result[1] <= 3:
print >>handle_2, '<span class="low">' + result[0] + '</span>' + ' ',
elif result[1] <= 6:
print >>handle_2, '<span class="medium">' + result[0] + '</span>' + ' ',
elif result[1] <= 9:
print >>handle_2, '<span class="high">' + result[0] + '</span>' + ' ',
else:
print >>handle_2, '<span class="top">' + result[0] + '</span>' + ' ',