CodeIgniter Forums

Full Version: Can I improve on this query handling?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

El Forum

I've got a simple blog engine with posts comments and tags.

My model calls in a post and also gets its comments and tags. For each post a number of records are retrieved depending on the amount of comments and/or tags.

I've got a loop going that returns a more usable array, but I'm sure there's a better way.

Here's the code

I find the overwrting of the post data every time very wasteful - is there a better way?

Many thanks,