I am refreshing myself on OOP with PHP and I saw an example of setting functions and/or variables as static. When and why would I set a variable/function to static? I\'ve
Generally using static function you can optimize the speed as well as memory and the scope of method should not be changed its should be static in nature and you can access the objects static properties ,methods without initiating them so saves the memory in mean time.