The log shows that Windows does not let PhpStorm write to the project folder, C:\inetpub\wwwroot\ProjectName. Every save fails, so your edits exist only in the editor. When PhpStorm reloads the file from disk, or after a restart, the old content comes back. That is why your changes appear to revert.
Every save failure in the log is an AccessDeniedException in this folder, e.g.:
com.intellij.openapi.diagnostic.UnhandledException: Cannot save C:\inetpub\wwwroot\yourDirectoryName\fileName.php.
Unable to create a backup file (fileName.php~).
The file left unchanged.
...
Caused by: java.nio.file.AccessDeniedException: C:\inetpub\wwwroot\yourDirectoryName\fileName.php -> C:\inetpub\wwwroot\yourDirectoryName\fileName.php~
PhpStorm also cannot write the .idea folder of the project, so it does not keep your project settings between sessions.
C:\inetpub\wwwroot is the IIS web root, and Windows usually restricts write access to it for standard user accounts. To fix the permissions: 1. Move the project to a folder in your user profile, for example C:\Users\<your user>\Projects\ProjectName. Then point the IIS site to that folder, or set up a deployment configuration that uploads the files to the web root. 2. Alternatively, give your Windows account the Modify permission on C:\inetpub\wwwroot\ProjectName. In addition, please make sure that Windows Defender or any other antivirus does not block phpstorm64.exe.
Could you share the log files so I'll have a look into this?
Help | Collect Logs and Diagnostic Data
Logs can be uploaded directly to our server - https://uploads.jetbrains.com (make sure to share the id of the upload here so that I can find it).
Hello Atransaction647,
The log shows that Windows does not let PhpStorm write to the project folder,
C:\inetpub\wwwroot\ProjectName. Every save fails, so your edits exist only in the editor. When PhpStorm reloads the file from disk, or after a restart, the old content comes back. That is why your changes appear to revert.Every save failure in the log is an
AccessDeniedExceptionin this folder, e.g.:PhpStorm also cannot write the
.ideafolder of the project, so it does not keep your project settings between sessions.C:\inetpub\wwwrootis the IIS web root, and Windows usually restricts write access to it for standard user accounts. To fix the permissions:1. Move the project to a folder in your user profile, for example
C:\Users\<your user>\Projects\ProjectName. Then point the IIS site to that folder, or set up a deployment configuration that uploads the files to the web root.2. Alternatively, give your Windows account the Modify permission on
C:\inetpub\wwwroot\ProjectName.In addition, please make sure that Windows Defender or any other antivirus does not block
phpstorm64.exe.