Reputation: 805
I'm trying to upload a file to a sever for a repository I am making. When I use FTP to upload the UDID.php the .php will map itself to the exact URL as it's name (ex using hi.txt http://my.site.org/hi.txt) I would like the UDID.php file to be mapped to another URL when I upload it (ex actual file is hi.txt and i want it to be mapped to http://my.site.org/example) Is there any way to do this? I am using iPage as my host if that helps
Upvotes: 1
Views: 1491
Reputation: 3887
FTP is purely a protocol for transferring files, so there's no way to "map" the request to a different file on the server. You could copy the file and give it a different name on the server, but I don't think that's what you're asking.
To achieve what you're setting out to do you would need to modify the web server configuration rather than the FTP connection, but I'm not sure it's a great idea :).
Copying fileA and naming it something different is trivial with FTP (once you've connected):
ftp> put project/hi.txt www/example
In the example above project/hi.txt
is the path to the file on your local machine, and www/example
is the path and filename it will be copied to on the server.
A lot of web hosts will have a public
or www
directory to put files to be served into.
Upvotes: 2