sul sito mi esce qst errore: Warning: mysql_result() expects parameter 1 to be resource, object given in

codice da me usato :

Codice PHP:
<div>  
            <? 
            $query 
"SELECT c.CAS_ID, c.TITOLO, i.NOME,c.DES_BREVE,c.DESC_ESTESA,c.OFFERTA_SPECIALE FROM `CASE` c LEFT JOIN `IMMAGINI` i ON c.CAS_ID = i.CAS_ID where VISIBLE = 1 and DEF = 1 and HOME = 1 order by c.CAS_ID DESC"
            
$result mysqli_query($mysqli $query); 
            
$num mysqli_num_rows($result); 
            
$i=0
            
$count 1
            while (
$i $num && $i <5) { 
                
$id_case[] = mysqli_result($result,$i,"CAS_ID"); 
                
?> 
                    <a style="border:1px solid #e2001a; margin-bottom:10px; display:block;" class="box_case" href="javascript:;" onClick="showCasa('bigbox_<? echo mysql_result($result,$i,"CAS_ID");?>'); updateStatCasa(<? echo mysql_result($result,$i,"CAS_ID");?>)">  
                        <table border="0" cellpadding="0" cellspacing="0" width="100%"> 
                            <tr> 
                                <td style="padding:15px 0 15px 15px; cursor:pointer;" width="120" align="center" valign="top"><img src="<?php echo mysql_result($result,$i,"NOME"); ?>" height="90" /></td> 
                                <td style="padding:15px 15px 15px 10px; cursor:pointer;" valign="top"> 
                                    <span style="font-weight:bold; font-size:12px; color:#13007d;"><?php echo mysql_result($result,$i,"TITOLO"); ?></span>  
                                    <br /> 
                                    <?php echo mysql_result($result,$i,"DES_BREVE"); ?> 
                                </td> 
                            </tr> 
                        </table> 
                    </a> 
                <? $i++;$count++; 
            } 
?> 
        </div>
nella riga 5 e 6 ho aggiunto la ' i ' alla funzione mysql e funziona, ma nella mysql_result nn va..
guardato anke il manuale php, ma nn riesco..
potreste darmi una mano?
grazie a tutti!!