Welcome Guest, Not a member yet? Register   Sign In
Best way to set global vars/constants?
#1

[eluser]Medikal[/eluser]
Hey guys, just curious. I have a ton of things I would like to set to global constants I can use anywhere just for ease of the use in the future in case I change anything. My best example is I'm constantly using $this->db->from("articles") or something of the sort, I'd rather have a constant defined as ARTICLES_TABLE and always refer to it as that so if the table name changed I could change it in one file for every query, among other things.

Cheers.


Messages In This Thread
Best way to set global vars/constants? - by El Forum - 12-20-2010, 08:03 PM
Best way to set global vars/constants? - by El Forum - 12-20-2010, 08:37 PM
Best way to set global vars/constants? - by El Forum - 12-23-2010, 02:21 AM



Theme © iAndrew 2016 - Forum software by © MyBB