I want to insert some text at the end of a Microsoft Word .doc file. The procedure will be called from php and that is the only requirement. It is a bit like saying: # echo "some text" >> file.txt in linux. Does anyone have any ideas about how this might be done? I have no idea how a Microsoft Word .doc file is formatted.