Thank you for all the responses. I digged deeper into static method and referred few books. It turns out that labeling any method static is purely based on coding 'style'. Then I looked into XF code and checked the method I've used frequently; 'get'
The description reads -
PHP:
/**
* getter method, basically same as offsetGet().
*
* This method can be called from an object of type Zend_Registry, or it
* can be called statically. In the latter case, it uses the default
* static instance stored in the class.
*
* @param string $index - get the value associated with $index
* @return mixed
* @throws Zend_Exception if no entry is registerd for $index.
*/
public static function get($index)
The description still does not give me any clue as to why the devs decided to mark it static. Maybe it's got something to do with Zend Framework? Would really appreciate if
@Mike could spare a moment to explain.
Thanks again for all the help!