Keep in mind that a .nomedia file only applies to multimedia apps so it's only about image and video content. So yeah, if you don't want the F-Stop Gallery app, the stock Gallery app, the Google Photos app, the VLC app, or whatever media app to not automatically scan, index, and display any of the content of a specific folder than you just need to add a .nomedia file.
But the Google Backup and Restore service that's a part of Android, that relates to the content of the file system, and a .nomedia file is irrelevant. Unless you intentionally created that PHP folder inside a Google app directory, odds are it's not included in your online Google account backup.