function __construct($transaction)
 {
     parent::__construct($transaction);
     $this->_gatewayName = get_string('payment_paypal_title', 'local_moodec');
     // Checks if sandbox mode is enabled
     if (!!get_config('local_moodec', 'payment_paypal_sandbox')) {
         $this->_gatewayURL = 'https://www.sandbox.paypal.com/cgi-bin/webscr';
         // the Paypal sandbox URL
     } else {
         $this->_gatewayURL = 'https://www.paypal.com/cgi-bin/webscr';
     }
 }
 function __construct($transaction)
 {
     global $CFG;
     parent::__construct($transaction);
     $this->_gatewayName = get_string('payment_dps_title', 'local_moodec');
     $this->_internalGatewayURL = new moodle_url($CFG->wwwroot . '/local/moodec/payment/dps/index.php');
     // Checks if sandbox mode is enabled
     if (!!get_config('local_moodec', 'payment_dps_sandbox')) {
         $this->_gatewayURL = 'https://uat.paymentexpress.com/pxaccess/pxpay.aspx';
         // the DPS sandbox URL
     } else {
         $this->_gatewayURL = 'https://sec.paymentexpress.com/pxaccess/pxpay.aspx';
     }
 }