Javascript examples for jQuery Method and Property:post
Run a python script through a web server and return results to javascript via $.post()
<html> <head> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js" type="text/javascript"></script> <script type="text/javascript"> function flipData(){/*w w w. j a v a 2 s . c om*/ $.post("http://localhost:38123/", { data: "makeitbackwards" }, function(data){ console.log(data); }, "json"); } </script> </head> <body> <a href="javascript:void(0)" onclick="flipData()">Get Time</a> </body> </html>