-1

I try to convert all MySQL codes to mysqli.

I stuck with this

$loginStrGroup  = mysql_result($LoginRS,0,'UserLevel');

I tried with some mysqli_result functions but nothing worked

Dharman
  • 30,962
  • 25
  • 85
  • 135

1 Answers1

0

mysql_result() was the second most misused mysql function, next to mysql_num_rows().

It should have never been used with mysql either.
A regular fetch should be used instead of that ugly crutch

$row = mysqli_fetch_assoc($LoginRS);
$loginStrGroup  = $row['UserLevel'] ?? false;
Your Common Sense
  • 156,878
  • 40
  • 214
  • 345