![]() |
Use of undefined constant data - assumed 'data' in C:\wamp\www\cms\yourpage.php on line 33 - 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: Use of undefined constant data - assumed 'data' in C:\wamp\www\cms\yourpage.php on line 33 (/showthread.php?tid=15941) |
Use of undefined constant data - assumed 'data' in C:\wamp\www\cms\yourpage.php on line 33 - El Forum - 02-19-2009 [eluser]adamsonit[/eluser] Code: <?php function nukeMagicQuotes() { Use of undefined constant data - assumed 'data' in C:\wamp\www\cms\yourpage.php on line 33 - El Forum - 02-19-2009 [eluser]TheFuzzy0ne[/eluser] You haven't used quotes, so PHP checks to see if any constants have been defined by that name. As there isn't one, it assumes it should be a string, and gives you a warning to let you know. Code: <?php echo $data['data']; ?> Use of undefined constant data - assumed 'data' in C:\wamp\www\cms\yourpage.php on line 33 - El Forum - 02-19-2009 [eluser]adamsonit[/eluser] thank you very much, it works. |