I am writing a script to 'flatten' (create a static version of) dynamic pages.
I want to get a php file from the local filesystem BUT I want PHP to parse and execute the file before returning it.
Similar to file_get_contents() but instead of returnin ghte php source code, I want it to process it and return the resulting page.
Any ideas?
I am currently using cURL which works, but uses up masses of bandwidth as it gets the file by absolute URL going out and back in through the firewall (I think).
Getting file from local filesystem after being parsed by PHP
Moderator: General Moderators
-
triggerhippy
- Forum Newbie
- Posts: 1
- Joined: Fri Mar 02, 2007 6:03 am
- feyd
- Neighborhood Spidermoddy
- Posts: 31559
- Joined: Mon Mar 29, 2004 3:24 pm
- Location: Bothell, Washington, USA
ob_start() is useful here.