file_get_contents problem

in my code use function file_get_contents for get output data of one php file
( the code line is here
$stringData = file_get_contents(“http://localhost/timologisi/tp1.php?idp=$invoiceid”); )
you can help me how use this in exeoutput because return error with this function ?
plus i can call direct file without localhost url ?


does not work because localhost doesn’t points to the internal server.

Yes, you can call a PHP script: see
For instance:
$cont = file_get_contents($_SERVER’DOCUMENT_ROOT’].‘include1.txt’, FILE_USE_INCLUDE_PATH);