php while loop variable for every third div

后端 未结 4 451
再見小時候
再見小時候 2020-12-10 16:23

Is their a way in a while loop to assign a variable to a class in a div, for every third item in a while loop. I am using the blueprint structure and the third div is at the

4条回答
  •  -上瘾入骨i
    2020-12-10 17:02

    $sql = "SELECT * FROM shoeData";
    $results = mysql_query($sql);
    while($row = mysql_fetch_array($results)) {
    
        // whatever code here 
    
    }
    

    It doesn't seem that MySQL is smart enough performing operations while comparing to true value you must specify $sql, $result because it looks like $row = mysql_fetch_array($results) is TRUE so it gets stuck on true loading the first row of data forever.

提交回复
热议问题