File editing question - Update file between 2 points?
Posted: Mon Jan 03, 2005 1:12 pm
Hi
I am wanting to use php to open a file and update data between two points.
Example:
this is other file content ----------------------------------------
this is other file content ----------------------------------------
this is other file content ----------------------------------------
this is other file content ----------------------------------------
this is other file content ----------------------------------------
this is other file content ----------------------------------------
<!-- UPDATE AREA START -->
updatable content here
<!-- UPDATE AREA END -->
Is this doable without exploding the whole files content into an array, storing, finding the update area, modify, then writing back...?
Can I just update between the comments???
Any help would be greatly appreciated.
Thanks
I am wanting to use php to open a file and update data between two points.
Example:
this is other file content ----------------------------------------
this is other file content ----------------------------------------
this is other file content ----------------------------------------
this is other file content ----------------------------------------
this is other file content ----------------------------------------
this is other file content ----------------------------------------
<!-- UPDATE AREA START -->
updatable content here
<!-- UPDATE AREA END -->
Is this doable without exploding the whole files content into an array, storing, finding the update area, modify, then writing back...?
Can I just update between the comments???
Any help would be greatly appreciated.
Thanks