Hello, I am having difficulties in converting the following to display the difference that has passed in hours and seconds in a nice way.
from datetime import datetime now = datetime.now() posted = date difference = now - posted namespace['date'] = date namespace['posted'] = difference when I look at the 'posted' namespace I get 23:08:31.454767 What is the best way to split this so that it will show '23h 08m 31s' ago or 1d 23h 08m 31s ago etc.. Thanks _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor