I created a public static function in a controller and I need to access a class property which is set on the constructor. I normally use $this->something to access such class properties, but this time, I got this error:
Using
$thiswhen not in object context
Here's the code:
public static function PayExecute() {
$paymentId = Input::get('paymentId');
$PayerID = Input::get('PayerID');
$cont = $this->apiContext;
}