• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Data not passing from controller to view

#4
[eluser]CroNiX[/eluser]
If you are sending $data['artist'] to your view, then in your view that variable is accessible by $artist, not $data['artist']. CI runs extract() on the $data array when sending it to the view.

If you want to still have the $data array defined (perhaps you want to group related data), then you need to send $data['data']['artist'] to the view and then $data['artist'] would be available.


Messages In This Thread
Data not passing from controller to view - by El Forum - 05-05-2013, 08:06 PM
Data not passing from controller to view - by El Forum - 05-06-2013, 07:02 AM
Data not passing from controller to view - by El Forum - 05-06-2013, 08:57 AM
Data not passing from controller to view - by El Forum - 05-06-2013, 10:24 AM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


Users browsing this thread:
1 Guest(s)


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