i'm trying to fetch data from mysql database using this code :
$con = mysqli_connect('localhost', 'root', '', 'nicu');
mysqli_query($con, "set NAMES utf8");
$query = mysqli_query($con, "select * from user");
while($rows = mysqli_fetch_assoc($query)) :
$rows = $rows["nicuAddress"];
$address = $rows["nicuEmail"];
echo "$rows<br>$address";
endwhile;
but every time i run this code i get this warning :Warning: Illegal string offset
what changes do i have to do to fix this ?