Dale_G Posted July 3, 2008 Share Posted July 3, 2008 Hey everyone, pretty basic question so I'll start off with an example. I have, on my server a file named "echo.txt" which has, in plain text, "echo 'hello world';". I also have a php file named "read.php". How can I read in "echo.txt" using "read.php" and attempt to PARSE whatever text is inside? So, say, if I update "echo.txt" to "echo 'hello there';", when I view "read.php" it will echo out "hello there" parsed straight from "echo.txt"? Link to comment https://forums.phpfreaks.com/topic/113159-solved-reading-in-php-externally-as-text-and-parsing-it/ Share on other sites More sharing options...
lemmin Posted July 3, 2008 Share Posted July 3, 2008 Put <?php ?> tags in echo.txt and use include "echo.txt"; in read.php Link to comment https://forums.phpfreaks.com/topic/113159-solved-reading-in-php-externally-as-text-and-parsing-it/#findComment-581389 Share on other sites More sharing options...
Dale_G Posted July 3, 2008 Author Share Posted July 3, 2008 Thanks. Link to comment https://forums.phpfreaks.com/topic/113159-solved-reading-in-php-externally-as-text-and-parsing-it/#findComment-581392 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.