What file extension do you use for your template/view files in PHP? [closed]
https://softwareengineering.stackexchange.com/questions/40389
-
30-10-2019 - |
سؤال
I'm building a Model-View-Controller framework, and it has come time to decide how I will be creating and using view templates and layouts.
Some frameworks use special extensions for these files. CakePHP uses .ctp
.
I have heard-of/seen .tpl
files, though I've never used them myself.
There is the .inc
extension, which doesn't feel right, and of course, I could stick with plaon ol' .php
.
For that matter why not .awesome
?
What do you use for your template files? Is there any benefit to using a special file extension for these files? Are you partial to a certain extension for nostalgia or convention alone? They're typically (and will be in my project) already in their own directory, so I assume there must be some reason they are differentiated by their extension in projects like CakePHP.
لا يوجد حل صحيح