extract render() HTML formatting method.