Welcome Guest, Not a member yet? Register   Sign In
posting the latest of something to the top of the row
#2

[eluser]Unknown[/eluser]
I would check the user guide (http://ellislab.com/codeigniter/user-gui...ecord.html) for the Active Record class and use $this->db->orderby(); passing the date stamp or id or whatever column you are trying to order by.

Of course, if you are using a query directly rather than Active Record, just include the ORDER BY clause in your SQL.

You shouldn't need to do anything with the array itself or any additional code.


Messages In This Thread
posting the latest of something to the top of the row - by El Forum - 10-19-2007, 02:24 PM
posting the latest of something to the top of the row - by El Forum - 10-19-2007, 02:53 PM
posting the latest of something to the top of the row - by El Forum - 10-19-2007, 02:59 PM
posting the latest of something to the top of the row - by El Forum - 10-19-2007, 03:42 PM
posting the latest of something to the top of the row - by El Forum - 02-27-2008, 02:58 AM



Theme © iAndrew 2016 - Forum software by © MyBB