Alberto Iglesias Well-Known Member Licensed User Longtime User Aug 23, 2016 #1 Anybody knows how I can show a PopUp with a simple HTML after do a POST in a webserver? After receive some data in this class "ReceiveData" I need show a popup with some results srvr.AddHandler("/ReceiveData", "ReceiveData", False)
Anybody knows how I can show a PopUp with a simple HTML after do a POST in a webserver? After receive some data in this class "ReceiveData" I need show a popup with some results srvr.AddHandler("/ReceiveData", "ReceiveData", False)
Erel B4X founder Staff member Licensed User Longtime User Aug 23, 2016 #2 You can use a Pane with WebView for that. Upvote 0
Alberto Iglesias Well-Known Member Licensed User Longtime User Aug 23, 2016 #3 Pane with WebView in a webserver? is gonna generate a html page to show in a browser? Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Aug 23, 2016 #4 No. For a server: https://b4x.com:51041/datepicker/index.html The code is available here: https://www.b4x.com/android/forum/threads/webapp-web-apps-overview.39811/#content Upvote 0
No. For a server: https://b4x.com:51041/datepicker/index.html The code is available here: https://www.b4x.com/android/forum/threads/webapp-web-apps-overview.39811/#content
Alberto Iglesias Well-Known Member Licensed User Longtime User Aug 23, 2016 #5 I see those samples, but no one have a popup AFTER a post, but I got what I needed. In this index.htm in a B4J webserver, you can get the result with jquery and show a dialog in a div, like this: My div in index.html B4X: <div id="dialog" title="Result" > </div> jquery in a index.html to receive the result after post B4X: <script type="text/javascript"> $("#form1").submit(function() { $.ajax({ type: "POST", url: "/ReceiveData", data: $("#form1").serialize(), success: function(result) { document.getElementById('dialog').innerHTML = result; $( "#dialog" ).dialog(); return false; }); Now is working perfectly! Upvote 0
I see those samples, but no one have a popup AFTER a post, but I got what I needed. In this index.htm in a B4J webserver, you can get the result with jquery and show a dialog in a div, like this: My div in index.html B4X: <div id="dialog" title="Result" > </div> jquery in a index.html to receive the result after post B4X: <script type="text/javascript"> $("#form1").submit(function() { $.ajax({ type: "POST", url: "/ReceiveData", data: $("#form1").serialize(), success: function(result) { document.getElementById('dialog').innerHTML = result; $( "#dialog" ).dialog(); return false; }); Now is working perfectly!