fixed template errors
Working version for Nexus7