This article explain how to solve the problem related to when there is problem saving the data to a text or any other file using php on a IIS server.
Solution includes following:
1. Check if the file name and path is correct
2. Check if the file is writable
to check this, right click the file to be written, and click properties, then make sure "read only" is not checked or dark.
3. Check if the permissions are set for the user
goto folder options and goto view tab, there uncheck the "simple file sharing"
then right click the file to be written, and click properties, there click on security tab,
make sure that the user "IUSR_" have all permissions, if you cant find the user there, create new user with this name and add permissions to it.
