Rename var to avoid conflicts
This commit is contained in:
parent
bf4a0e46aa
commit
3c8c5102c3
@ -1384,7 +1384,7 @@ if (preg_match('/^dopayment/',$action))
|
||||
/*
|
||||
print '<script src="https://checkout.stripe.com/checkout.js"
|
||||
class="stripe-button"
|
||||
data-key="'.$stripe['publishable_key'].'"
|
||||
data-key="'.$stripearrayofkeys['publishable_key'].'"
|
||||
data-amount="'.$ttc.'"
|
||||
data-currency="'.$conf->currency.'"
|
||||
data-description="'.$ref.'">
|
||||
@ -1469,7 +1469,7 @@ if (preg_match('/^dopayment/',$action))
|
||||
?>
|
||||
|
||||
// Create a Stripe client
|
||||
var stripe = Stripe('<?php echo $stripe['publishable_key']; ?>');
|
||||
var stripe = Stripe('<?php echo $stripearrayofkeys['publishable_key']; // Defined into config.php ?>');
|
||||
|
||||
// Create an instance of Elements
|
||||
var elements = stripe.elements();
|
||||
|
||||
@ -38,12 +38,10 @@ if (is_numeric($entity)) define("DOLENTITY", $entity);
|
||||
require '../../main.inc.php';
|
||||
|
||||
require_once DOL_DOCUMENT_ROOT.'/stripe/config.php';
|
||||
/* included into config.php
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/payments.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/stripe/lib/stripe.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/includes/stripe/init.php';
|
||||
*/
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
|
||||
|
||||
// Security check
|
||||
if (empty($conf->stripe->enabled)) accessforbidden('',0,0,1);
|
||||
@ -1096,7 +1094,7 @@ if (preg_match('/^dopayment/',$action))
|
||||
/*
|
||||
print '<script src="https://checkout.stripe.com/checkout.js"
|
||||
class="stripe-button"
|
||||
data-key="'.$stripe['publishable_key'].'"
|
||||
data-key="'.$stripearrayofkeys['publishable_key'].'"
|
||||
data-amount="'.$ttc.'"
|
||||
data-currency="'.$conf->currency.'"
|
||||
data-description="'.$ref.'">
|
||||
@ -1182,7 +1180,7 @@ if (preg_match('/^dopayment/',$action))
|
||||
?>
|
||||
|
||||
// Create a Stripe client
|
||||
var stripe = Stripe('<?php echo $stripe['publishable_key']; ?>');
|
||||
var stripe = Stripe('<?php echo $stripearrayofkeys['publishable_key']; ?>');
|
||||
|
||||
// Create an instance of Elements
|
||||
var elements = stripe.elements();
|
||||
|
||||
Loading…
Reference in New Issue
Block a user