13 global $wgDonationInterfaceTest,
14 $wgDonationInterfaceTemplate,
15 $wgDonationInterfaceErrorTemplate,
16 $wgDonationInterfaceMessageSourceType,
21 if ( !isset( $wgDonationInterfaceTest ) || $wgDonationInterfaceTest !==
true ) {
22 $wgDonationInterfaceTest =
false;
28 $wgDonationInterfaceTemplate = __DIR__ .
'/gateway_forms/mustache/index.html.mustache';
33 $wgDonationInterfaceErrorTemplate = __DIR__ .
'/gateway_forms/mustache/error_form.html.mustache';
38 $vendorAutoload = __DIR__ .
'/vendor/autoload.php';
39 if ( file_exists( $vendorAutoload ) ) {
40 require_once $vendorAutoload;
42 require_once __DIR__ .
'/gateway_common/WmfFramework.php';
44 if ( defined(
'MEDIAWIKI' ) ) {
46 $spConfig = GlobalConfiguration::create();
47 Context::init( $spConfig );
48 $context = Context::get();
49 $context->setSourceName(
'DonationInterface' );
50 $context->setSourceType( $wgDonationInterfaceMessageSourceType );
51 $context->setVersionFromFile(
"$IP/.version-stamp" );