梦里花落0921
您可以尝试如下操作:HTML:<input type='button' value='Call Procedure' id='BtnId'>jQuery的:$(document).ready(function(){ $("#BtnId").on( 'click', function(){ $.ajax({ type : "POST", url : "callsp.php", success : function(text){ alert(text); } }); return false; }); });PHP: (callsp.php)<?php// connect to database$connection = mysqli_connect("hostname", "username", "password", "db", "port");// run the query$result = mysqli_query($connection, "CALL DeleteRow") or die("Query Failed: " . mysqli_error());// loop the result setwhile( $row = mysqli_fetch_array($result) ) { print_r( $row );}?>