![]() |
Logic Machine Communication - HTTP - Printable Version +- Logic Machine Forum (https://forum.logicmachine.net) +-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1) +--- Forum: Scripting (https://forum.logicmachine.net/forumdisplay.php?fid=8) +--- Thread: Logic Machine Communication - HTTP (/showthread.php?tid=712) |
Logic Machine Communication - HTTP - Rodriguez - 31.03.2017 Hello, I would like to know, how can I take information from an HTTP page from the logic machine? ![]() RE: Logic Machine Communication - HTTP - admin - 31.03.2017 http://w3.impa.br/~diego/software/luasocket/http.html#request RE: Logic Machine Communication - HTTP - Erwin van der Zwart - 31.03.2017 Hi, If you just need a simple datafield you can also use: Code: require('socket.http') Erwin RE: Logic Machine Communication - HTTP - Rodriguez - 31.03.2017 Hi, Erwin van der Zwar: Thanks for your help. Yes, it is a simple data capture, use your code but it is not registering anything to me. RE: Logic Machine Communication - HTTP - Erwin van der Zwart - 31.03.2017 Hi, The data is now fetched between <h2> </h2> fields but i don't know the fields in your html mark-up so you have to check that and change it to those.. log(data) to see your complete reply from your url source.. or right click your source in the browser and select 'view source code' to see the structure of the site you read.. BR, Erwin RE: Logic Machine Communication - HTTP - admin - 01.04.2017 Check is gateway and DNS are set in network config. RE: Logic Machine Communication - HTTP - Erwin van der Zwart - 01.04.2017 Hi, I adjusted the sample to a (tested) version to fetch all the main topics from this forum Code: require('socket.http') BR, Erwin RE: Logic Machine Communication - HTTP - Rodriguez - 04.04.2017 It works, thanks for your help. ![]() |