There is a great little piece of code to display x most recent nodes from a list of terms

Could someone help me modify this so I can display (x+3) through (x + 10) latest knows (ie list the 4th through 8th latest stories from a taxonomy set). I've been looking at the code, and it occurs to me that it probably isn't too hard. But I can't seem to get my brain around it.

Thanks for your help.

Comments

mooffie’s picture

The db_query_range(..., 0, $count) actually stands for db_query_range(..., $offset, $count).

That is,

to display stories #4 to #8 (exclusive), do db_query_range(..., 3, 5)

to display stories #20 to #100 (exclusive), do db_query_range(..., 19, 81)