Global Variable - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: General (https://forum.codeigniter.com/forumdisplay.php?fid=1) +--- Forum: Lounge (https://forum.codeigniter.com/forumdisplay.php?fid=3) +--- Thread: Global Variable (/showthread.php?tid=70217) |
Global Variable - Prateek - 03-09-2018 Hi, Is there any way to create global variable in CI which can be accessed from any of the Model or Controller .(Note Variable is not Static) Thank you. Prateek Sinha RE: Global Variable - jreklund - 03-09-2018 You can set and get a Config file. https://www.codeigniter.com/user_guide/libraries/config.html RE: Global Variable - emmawatson8855 - 04-03-2018 You can also find some informative information about global variable on StackOverflow https://stackoverflow.com/questions/17013397/code-igniter-best-place-to-declare-global-variable?utm_medium=organic&utm_source=google_rich_qa&utm_campaign=google_rich_qa |