php - How to get value from mysqli_query -


i using mysqli_query

select count( statid ) device_realtime_stats 

in statement, in db returns value ex:3

i want integer in php. giving this

$rows_count = mysqli_query($con, " select count( statid ) device_realtime_stats "); 

but not returns integer, how convert. want integer value in php

you can count

// return mysqli statement not integer $rows_count = mysqli_query($con, " select count( statid ) count device_realtime_stats ");  $count = mysqli_fetch_object($rows_count)->count; // return count want 

Comments

Popular posts from this blog

javascript - Unusual behaviour when drawing lots of images onto a large canvas -

how can i manage url using .htaccess in php? -

javascript - Chart.js - setting tooltip z-index -