Better templating but still issues with displaying data