User Tools

Site Tools


lua:curl_example

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
lua:curl_example [2023/10/26 14:14] – [Writing some file onto WebHMI filesystem] emozolyaklua:curl_example [2023/10/26 14:23] emozolyak
Line 1: Line 1:
 +====== Getting some data from WebHMI itself using API ======
 +
 <code lua> <code lua>
          
Line 44: Line 46:
                 upload = true,                 upload = true,
                 timeout = 2,                 timeout = 2,
-                readfunction = function()  +                readfunction =  
-                                        if (not done) then  +                function() if (not done) then done = true return fileContent end end } 
-                                            done = true  +    c : perform(); c : close() 
-                                            return fileContent +
-                                        end  +
-                               end } c : perform(); c : close() +
 end end
  
lua/curl_example.txt · Last modified: 2024/01/18 12:58 by atolstov

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki