More robust CMS_TEMPLATE implementation
Merge pull request #2708 from yakky/feature/fix_page_template

More robust CMS_TEMPLATE implementation
Merge branch 'develop' into fix-2267

Conflicts:
	cms/context_processors.py
	cms/tests/views.py