Jump to content

Object of class mysqli_result could not be converted to int


bravo14

Recommended Posts

Hi all

 

i am using the code below, but am getting the error

 

Object of class mysqli_result could not be converted to int

 

 

<?php
  $sql="SELECT lng,lng_prefix FROM tbl_languages where active = 1";
  $result=mysqli_query($dbConn, $sql)or die(mysqli_error($dbConn)); //problem line
  if(mysqli_num_rows($result==1)){
      ?>

 

The code continues with what I want to happen based on the result.

 

What does the error mean and how do I fix it?

Link to post
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.