This code will show just the even or odd rows using mysql
1 2 3 4 |
$result = mysql_query("SELECT * FROM test where (id,0) in (select id, mod(id,2) from test);"); // change (id,0) to (id,1) to get odd or even rows |
// id is field