Re: Calling PHP from PHP
| From: | Alf Stockton | Date: | Thu, 12 Apr 2007 11:32:19 +0000 |
| Subject: | Re: Calling PHP from PHP | ||
| References: | 1 2 3 | Groups: | php.windows |
| Request: | Send a blank email to php-windows+get-27676@lists.php.net to get a copy of this message | ||
Mikael Grön wrote:
Sidenote: You can also do: $dir = "folder/of/include/files"; $files = opendir($dir); while ($file = readdir($file)): if (substr($file,-4) == '.php'):If I was going to include then I may as well have coded that script into the "calling" script and duplicate the stuff all over my system. Maybe too much of my C programming background is showing but I just want to call another script, the same as one would in C by calling another program. -- Regards, Alf Stockton www.stockton.co.za Beware of a dark-haired man with a loud tie. My email disclaimer is available at www.stockton.co.za/disclaimer.htmlinclude_once($dir.'/'.$file);endif; endwhile; but I wouldn't recommend it. :P No neither would I recommend that solution and anyway I don't in any way want to do an include.