abitshort Posted December 13, 2009 Share Posted December 13, 2009 $result = query_read("SELECT * FROM schedule WHERE live = 1 ORDER BY DESC"); while($r = fetch_array($result)){ $lala .= "<div>$r[instructor]</div> <div><b>$r[class]</b></div> <div><i>$r[level]</i></div> <div>$r[time] on $r[day]</div>"; } it turns out to be like this: Instructor A Class A Level A Time A --- Day A and Instructor A Class A Level A Time B --- Day B How do i turn it to something like this: Instructor A Class A Level A Time A --- Day A and Time B --- Day B Link to comment https://forums.phpfreaks.com/topic/184949-mplae-question/ Share on other sites More sharing options...
fenway Posted December 14, 2009 Share Posted December 14, 2009 You build your own structure in one pass, then output it in a second pass. Link to comment https://forums.phpfreaks.com/topic/184949-mplae-question/#findComment-977301 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.