HTML vs SHTML vs PHTML

27.7k views Asked by At

What is the difference between:

HTML
SHTML
PHTML

Why and when i'll use which one?

3

There are 3 answers

2
GrayWizardx On BEST ANSWER

It looks like SHTML = Server Side include HTML (SSI), which is just a fancy way of saying the server can dynamically inject code at the reference point (i.e. where the include is).

PHTML is HTML code with inline PHP processing instructions.

0
Eli Grey On

Use static HTML when you want to have static content. Use SHTML if you want to do simple things such as includes. Use PHTML if you want to use logic (though it's possible to do with SHTML if you really want to).

1
vuchkov On

.phtml is usual extension to Phalcom PHP Framework files :)
Ref.: https://docs.phalconphp.com/en/latest/reference/tutorial.html