EllisLab text mark
Advanced Search
     
User Guide Tutorial
Posted: 10 April 2012 01:59 PM
Joined: 2012-04-10
2 posts

Hi,

I’m new to OOPHP and CI.  (Yay for newb questions!)  rolleyes 

I did search around the forum and haven’t found this specific answer, albeit most of the answers are over my head anyway.  I’m only about 2 days into learning CI and OOPHP, although I have ~12 years of procedural PHP experience.


I have followed the News tutorial News Tutorial Page and I found one part to be vague enough not to follow fully and I think this is where my issue is coming from…  which is… nothing is showing in the view.

The potential “offending section”:

Now the data is retrieved by the controller through our model, but nothing is displayed yet. The next thing to do is passing this data to the views.

public function index()
{
 $data[
'news'$this->news_model->get_news();
 
$data['title''News archive';

 
$this->load->view('templates/header'$data);
 
$this->load->view('news/index'$data);
 
$this->load->view('templates/footer');

So,  My question: Specifically,  where does this code go? 
currently it’s sitting in ~/public_html/application/controllers/page.php

If this is right, then I’m completely lost.

TIA for any help!
Mike

 
Posted: 10 April 2012 02:52 PM   [ # 1 ]   [ Rating: 0 ]
Joined: 2012-04-10
2 posts

haha….

You’re all laughing at me aren’t you?  I can tell. 

So I figured it out.  Sorry to waste bandwidth.

 
Posted: 10 April 2012 08:08 PM   [ # 2 ]   [ Rating: 0 ]
Joined: 2011-11-04
244 posts
polloraro - 10 April 2012 02:52 PM

haha….

You’re all laughing at me aren’t you?  I can tell. 

So I figured it out.  Sorry to waste bandwidth.

It’d probs be a good idea to post in the correct forum next time, as you’re more likely to get a response on coding help there.

http://ellislab.com/forums/viewforum/127/

And yeah, it would go there.