• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Problems getting foreach loop to display data

#11
[eluser]douglasbrownca01[/eluser]
Yep, that gets me one result -- but as I read that -- it's just looking for the first item in the array object. I want to return a set of rows into a table. So is there a way to loop it in the view to bring back the full contents of the array?

I guess what i don't understand is why the original $fingerguard->item_code didn't work and just loop through the dataset like it did in the get_accessories function.

#12
[eluser]douglasbrownca01[/eluser]
Yep, that gets me one result -- but as I read that -- it's just looking for the first item in the array object. I want to return a set of rows into a table. So is there a way to loop it in the view to bring back the full contents of the array?

I guess what i don't understand is why the original $fingerguard->item_code didn't work and just loop through the dataset like it did in the get_accessories function.

#13
[eluser]douglasbrownca01[/eluser]
Ok, I figured it out -- or at least where my mistake was. My original approach was correct with building the queries all under the get_accessories() function in my Model. I was returning the results early -- I've got it working correctly now for multiple instances. Thanks for all your help.


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


Users browsing this thread:
1 Guest(s)


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2019 MyBB Group.