Uploading a file in Pre/Post Export Methods

Hi,

We use UCB’s Pre/Post Export Methods script to build asset bundles and upload them to our server.
Although the asset bundles build seem to be successful, upload process does not work.
A snippet of the script for uploading a file is as follows:

byte[ ] data = File.ReadAllBytes (filepath);
WWWForm form = new WWWForm ();
form.AddBinaryData (“file”, data, “example.unity3d”);
Debug.Log (“################################## before”);
WWW www = new WWW (“http://www.example.com/ucb/upload”, form);
Debug.Log (“################################## done”)

The debug log “###…## done” is found in Full Build Log on UCB console, but I cannot find any access log on my web server, so that I don’t think UCB build process attempted to connect to the server.

Could you tell me the way to upload a file to external server in Pre/Post Export Methods script?

Hi and welcome to the forums!

Have you already tried to push a small test file?