miumax Posted August 11, 2016 Share Posted August 11, 2016 in My module I'm try to make a order from cart. in my modules controller file I'm calling validateOrder PaymentModule::validateOrder((int)$urbCart->id, $order_status, $order_total, "urb-it", NULL, array(), (int)$currency->id, false, $urbCart->secure_key); for create a order. Hove ever I got below error.PHP Fatal error: Cannot access protected property UrbitOrderCompleteModuleFrontController::$context in /opt/webapp/urbit/classes/PaymentModule.php on line 171The payment module error is happen in (line 171) is below if (!isset($this->context)) { $this->context = Context::getContext(); } Why that context is say as protected property ? How can I create order ? Link to comment Share on other sites More sharing options...
bellini13 Posted August 11, 2016 Share Posted August 11, 2016 the validateOrder function is not a static function, so you cannot use it like PaymentModule::validateOrder instead, you do this $this->module->validateOrder(.....) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now