Skip to content
Advertisement

Get return value from mySQL stored procedure in PHP

I have a stored procedure that return list of users but when I call this procedure in php Just return me this message: {“status”:true,”data”:[{“userID”:0}]}

this is my S.P.

JavaScript

and this is my PHP code

JavaScript

Edit: I used do/while to fetch all records but now I get extra data about fields spec. This is my new code

JavaScript

this is result:

JavaScript

Advertisement

Answer

My edited code was working correctly. I just need to comment “var_dump($users);”

User contributions licensed under: CC BY-SA
1 People found this is helpful
Advertisement