Page 1 of 1

how i include example.php file into index.html?

Posted: Sat Jan 23, 2010 8:44 am
by venkatesh.svs
can anybody help to include example.php file into index.html?

Re: how i include example.php file into index.html?

Posted: Sat Jan 23, 2010 8:45 am
by timWebUK
You don't, you would include example.php within index.php

Code: Select all

<?php
 
include 'example.php';
 
?>

Re: how i include example.php file into index.html?

Posted: Sat Jan 23, 2010 10:09 am
by SimpleManWeb
You don't, you would include example.php within index.php
I completely agree with timWebUK, you should change your index.html file to index.php and then your include will work. However, I have seen sites in the past that have successfully included a php file within a html file. I'm not sure what the settings on the server need to be in order for this to work, but it is possible.