Access my server files through http
What is the right 开发者_如何学JAVAHTTP URL format I could use with URLConnection to access my files in my server. For example my file in C:\myfolder\myfile.ext and my servers
You could host those files on a network share, there is native support for this in Windows, Mac, and *Nix based systems and it's relatively easy. If the files are not pushed through that computer's web server software (apache, nginx, etc.) then it cannot be accessed with the http protocol, but can be access through samba or some other local network sharing protocol. For exmaple, the syntax for windows UNC is:
\\ComputerName\SharedFolder\Resource
or with samba (smb)
smb://hostname/directorypath/resource
精彩评论