Well, of course you can't simply write or copy files to a path using an IP address. (How secure would our networks be???) File writing and copying assumes
local hard drive paths, or mapped network paths (Windows file share, NFS, etc...), not just generic network paths, and what protocol are you trying to use when you write to the IP address?
Since it seems you are using Windows, I'll assume you are trying to save to another windows system: it's the same as if you as a local user on the server trying to save a file somewhere. Either you use a local path, such as C:\\..., or you map a network location to a hard drive letter, such as F:\\, then you treat it as a local address. I suppose you could try to direct PHP to navigate a windows network share, with paths such as "\\servername\directory", but I doubt it is that simple.
Also, there is the question of user permissions. If you are using NT, I'm not totally sure how to approach this. I suppose you could just share your remote server directory with "Everybody->Full Control", but that is pretty insecure. If you are using IIS, then I believe the default user for the server process is IUSR_{servername}, but I'm not totally sure about that. Anyway, standard Windows network share permission methods should apply to this situation.
Or... if you installed PHP with FTP functionality, then you could use the FTP functions to save a files to any remote server that is running FTP server. Otherwise, you should map your network drive, and let PHP treat the path as a local one. -------------------
Current reading --