pytz timezone tags to adjust date printed in templates
问题 Inside my app I use normal datetime objects. In my template: {% load tz %} {{datetimeobject|timezone:"Europe/Paris"}} {% timezone "Europe/Paris" %} {{datetimeobject}} {% endtimezone %} This prints something like this: Dec. 5, 2012, 4 p.m. Dec. 5, 2012, 3 p.m. So the timezone filter adjusts the date but timezone tag DOES NOT. Why is that? And how I can use tag properly? My goal is to adjusts all datetimeobjects in whole template without adding filter to every datetimeobject printed in template