Not everybody has access to a MySQL database or wants to use one. Often data is stored in other files on your server. If this is the case, you can use PHP to retrieve the data from these files to use. Depending on the function you use, the data can be returned to you as a string or as an array. Your options are also limited by how the file you are trying to access is formatted.


Is there a Function that can execute a PHP page (I need it to execute a file in a block in my index page)?
Like “Server.Execute()” in ASP ..
Thanks for help and sorry about my weak English.
What method would wait for the page to fully load before the file download begins, in the case if java is on the page?
@Uriya:
do you mean that you have a php file or a txt file in php language…and you want to include its contents into the index page ? (example:)
the file contains:
HomePage | Forums
REMEMBER: THE FILE YOU WANNA ADD CANT CONTAIN THE PHP TAGS ()
ONLY THE CONTENT(like: echo $myvar;)
the index contains:
and you wanna include it after the text (here is the menu:)
so you add INCLUDE “./menu.html”;
and the index.php will be:
NOTE: the ‘./’ means the directory that the current file in – the ‘../’ means the directory that the directory of this file included in
example: the path that the php file in is:
c:\webserver\myphp
./example.php means c:\webserver\myphp\example.php
../example.php means c:\webserver\example.php