I’ve been working on a method to POST a file to a remote webserver.
The method works correctly when selecting a test file, or hardcoding a file path in the method.
But, when trying to pull the file from the database - referring to the blob data field directly, using a blobloader url or using JSfile or Getimage methods - it will always fail and the poster.addfile method returns false.
This particular solution is still on 3.5.10. Plans to upgrade are coming, but need this feature now.
I’d like to not have to write to the users harddrive first (unless someone has some code for a handsfree and OS independent directory path).
I thought the blob loader would work:
var img_url = ‘media:///servoy_blobloader?servername=’ + controller.getServerName() + ‘&tablename=media&dataprovider=media_data&rowid=’ + media_id
var AddParam1 = poster.addFile(‘uploaded_file’,‘test.png’,img_url);
Is there really no way to “attach” a database file to an HTTP post via poster.addfile?