Jump to content

solve a fopen fwrite problem


terryoleary1981

Recommended Posts

Hi guys

I've not used the file method extensively but i'm currently creating a web application. What i was to happen is a set of html files reside in a folder i copy these files via a php script and place them into a folder (already created)

then what i want to do it to parse the file and when certain flags appear in the page i want to write to the file

for example if i had this template

....
<body>
<h1> hello %name-here%</h1>
</body
....


i'd want to parse this file and match the %name-here% at which point the php file can write to the page and replace it with something from a database?

does that make sense i hope so, if anyone can tell me how to write to a file at a certain position would be much appreciated all i can find is appending to the end of the file

- Terry
Link to comment
https://forums.phpfreaks.com/topic/27442-solve-a-fopen-fwrite-problem/
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.