Jump to content

Parsing PHP (template engine help)


GuitarGod

Recommended Posts

Hi folks.

 

I'm building a simple template engine and need help parsing PHP. For getting the HTML source of the file, I use the file_get_contents function. In the template, I have simple strings like <!-- FOR ...etc... --> which using the str_replace function, gets changed into <?php for etc ... ?>. The only problem is, the final output isn't parsed. When I view the source code, I actually see the <?php ... ?>. If you don't understand what I mean I'll post a code example. Is there any way round this? How can I get the final output to be parsed?

 

Thanks a lot  ;D

Link to comment
https://forums.phpfreaks.com/topic/163368-parsing-php-template-engine-help/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.