![]() |
Passing variable to view not working... - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Passing variable to view not working... (/showthread.php?tid=6072) |
Passing variable to view not working... - El Forum - 02-13-2008 [eluser]Chris.Campbell[/eluser] I really cannot figure this out.. any help is greatly appreciated. My controller: Code: <?php My view: Code: <?php echo $data['username']; ?> The error: Quote:A PHP Error was encountered Passing variable to view not working... - El Forum - 02-13-2008 [eluser]Seppo[/eluser] In your view you have to use <?php echo $username; ?>. The array passed to the view is "extracted" Passing variable to view not working... - El Forum - 02-13-2008 [eluser]Chris.Campbell[/eluser] Thanks |