i want get next and previoes row information in mysql_fetch_arr ay in whilew loop with the current row

Code:
while($result=mysql_fetch_array($sqlcate1)){
				?>

                <tr class=gradeX>
                  <td><?php echo $m++;?></td>
                  <td><?php echo $result['cat_name']?></td>
                  <td><?php echo $result['title'];?></td>
...