B4J Question How to upload file with http - jinyistudio    Mar 11, 2018   (1 reaction) following is ok :) ' send image file by line notify Sub lineNotify3(token As String, imageUrl As String) Dim url As StringBuilder url.Initialize url.Append($"https://notify-api.line.me/api/notify"$) ' Dim fd As MultipartFileData fd.Initialize fd.KeyName="imageFile" f B4J Question Upload File to a Web Server - MegatenFreak (first post)    Apr 17, 2022   (1 reaction) My method is by putting a small PHP script on the website and sending it the file using MultipartFileData:
Dim Job As HttpJob
Job.Initialize("", Me)
Dim Link As String = "http://www.mysite.com/api.php" 'Link to the php script or API or anything that's going to receive the file
Dim Files As List
D B4A Question Upload text file with OkHttpUtils2 - DonManfred (first post)    Jan 05, 2019   (1 reaction) To upload a file to a Server there must be an Serverpart running which accept the file to upload.
You can not specify just a folder on your webspace and expect you are able to upload anything there.
A httpjob.Postmultipart will create a multipart-post-request to the server. On the serverside the fi B4A Code Snippet Upload a file to your server with HttpJob and php(included) - scottie    Apr 26, 2020   (8 reactions) 4-25-2020
Pick a SINGLE File from Dialog box, Then upload it To a server on LAN Or Internet
I wrote this B4A To be very small, simple, & easy to understand on a beginners level
In Files Is the PHP script To handle single File upload And save As original filename
php creates And appends a logfile: b4 B4A Question Upload file to www - DonManfred (first post)    Dec 14, 2016 To upload files to your webserver usually ftp is used.
You can use httputils if your server expect files and a php-script copies the file to the right place.
I mean you have a php-script running which will receive fileuploads. B4i Question Upload file - nwhitfield (first post)    Sep 28, 2017   (1 reaction) Append(EOL)
formStream.WriteBytes(tail.ToString.GetBytes("UTF8"),0,tail.Length)
' post to the URL
Log("Form prepared")
Dim uploader As HttpJob
uploader.Initialize("upload",BLUFios)
uploader.PostBytes(BLUF.uploadURL,formStream.ToBytesArray)
uploader.GetRequest.SetContentType("multipart/form-data; B4J Library [BANanoVueMaterial]: The first complete opensource VueJS UX based framework for BANano - Mashiane (first post)    Feb 14, 2020   (1 reaction) We upload each file in the file list by calling... Sub HTTPUpload(fileObj As Object, module As Object, methodname As String) Dim promise As BANanoPromise 'ignore ' some vars to hold our results Dim Error As String Dim json As String ' call the http request promise.CallS B4J Tutorial Easy upload files with httputils' original poststring to a php script with x parameters - KMatle    Nov 06, 2015   (5 reactions) The file is converted back from Base64 and written in the given folder with the given filename.
<?php
$jsonstring = file_get_contents("php://input");
$jsonlist = array();
$jsonrow = array();
$jsonlist=json_decode($jsonstring, true);
$jsonrow=$jsonlist;
$ServerFolderName= B4A Question Upload file, e.g. jpg using okHttUtils2 - Hanz    May 12, 2021 A service or a server, not B4J server, is accepting the ff. HTTP PUT command.
curl -vX PUT http://admin:[email protected]:.jpg?rev=2-2739352689 --data-binary @artwork.jpg -H "Content-Type:image/jpg"
I tried the sample provided by the link below to implement it in B4A, but I can't get it run.
U B4A Question Uploading file using httputils2 - KMatle (first post)    Dec 21, 2016   (1 reaction) Yep. I prefer this:
Dim FileBuffer(0) As Byte
FileBuffer=Bit.InputStreamToBytes(File.OpenInput(FilePath,FileName))
Dim B64String As String
Dim su As StringUtils
B64String=su.EncodeBase64(FileBuffer)
In the MySQL db define a field as longtext and store it (=B64String) as a normal stri Page: 1   2   3   4   5   6   7   Powered by ColBERT |