![]() |
PHP - Parsing PHP in includes
I'm trying to include() a file that has a .txt extension. What I'd like to do is parse some PHP on that text file as well.
It's not working What I have done is set .txt as php parsable in htaccess. No go. Any ideas? |
Why not just make the .txt a .php extension and include it?
Otherwise maybe you can try something like the eval function http://us2.php.net/eval and see if that works. -- below may or may not work for you -- $text = join('', file('/path/to/text/file')); echo eval($text); |
have it as .php and dont forget about opening and closing php tags <? ... ?> inside the include file.
|
Quote:
|
All times are GMT -7. The time now is 02:00 PM. |
Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123