[eluser]Medikal[/eluser]
Alright so I have an article that lists comments just fine, however it pulls it from a comments table, so it doesn't say posted by their username, it says posted by their userID. I made a function in my user model that requires the id as the only argument, and returns the row with all their information.
I output the page like so:
$viewDeal['thisDeal'] = $this->deals_model->viewdeal();
$viewDeal['comments'] = $this->deals_model->grabcomments();
$viewDeal['main_content'] = 'viewdeal_view';
$this->load->view('includes/template', $viewDeal);
So on the view file I can do $comments->userID and it will display the ID, I'm trying to find the username which is in a different table. I can do this in an inefficient manner, I'm just trying to learn the traditional MVC nature of where I would do it.
Thank you.