Templates, scripts and best practices for ePub and html publishing