<?php
$conn = mysql_connect('localhost','root','');
mysql_select_db('dbname',$conn);
mysql_query("call pro2(2,@uname)");
$query = mysql_query('select @uname');
$row = mysql_fetch_row($query);
print_r($row);
?>
转载于:https://blog.51cto.com/seetobest/1398833