Upload File To A Website Via Python Script
Solution 1:
For a similar task, I've previously used mechanize, with some quite success. Note: although I was not uploading files, its documentation says that it is capable to handle also file uploads.
Solution 2:
Okay, you want to use Python to upload a file using HTTP "put". You will need to use a Python library that lets you do HTML stuff; a good choice might be httplib which is included with Python.
A Google search for "Python HTTP put" found me this:
http://inamidst.com/proj/put/put.py
This appears to be complete working code that solves your problem.
Solution 3:
You mention they do not offer FTP, but I went to their site and found the following:
How to upload with FTP? ftp.hotfile.com user: your hotfile username pass: your hotfile password You can upload and make folders, but cant rename,move files
Try it. If it works, using FTP from within Python will be a very simple task.
Post a Comment for "Upload File To A Website Via Python Script"