How to define constants globally in CodeIgniter

category:  CodeIgniter, Web development

When you are developing the web application, you want to set the constants that you will use in the application globally. For example, you want to set the application name, application version or salt key for encrypt the password. In CodeIgniter, it provides the place for this purpose. Constants.php In application/config/constants.php, it is a file that you can define your constants globally. In the constants.php, you will see some constants in there. Go to the end of file and add … Read More