What is the difference between php and html file extensions? -
i having .php
file following code. while changing extension of file .html
behaving in same way. can explain following:
- why file behaving in same manner both extensions?
- what difference between
.php
,.html
file extensions?
.php
file
<html> <head> <!-- html code --> </head> <body> <?php echo "hello!" ?> </body> </html>
the filetype way identify file, can't trust them.
depending on web server configuration, see different results.
.html use html no serverside code.
.php used serverside php code , html if required.
they can used anything, depends on setup.
Comments
Post a Comment