Skip to content

Commit

Permalink
Better code
Browse files Browse the repository at this point in the history
  • Loading branch information
eldy committed Apr 24, 2019
1 parent 79c37f2 commit 8d28506
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions htdocs/public/payment/newpayment.php
Expand Up @@ -1727,26 +1727,28 @@ class="stripe-button"
<tbody><tr><td class="textpublicpayment">
<div class="form-row left">
<label for="card-element">
'.$langs->trans("CreditOrDebitCard").'
</label>
<label for="card-element">'.$langs->trans("CreditOrDebitCard").'</label>
<div id="card-element">
<!-- a Stripe Element will be inserted here. -->
</div>
<!-- Used to display form errors -->
<div id="card-errors" role="alert"></div>
</div>
<br>
<button class="butAction" id="buttontopay">'.$langs->trans("ValidatePayment").'</button>
<img id="hourglasstopay" class="hidden" src="'.DOL_URL_ROOT.'/theme/'.$conf->theme.'/img/working.gif'.'">
</td></tr></tbody></table>
</form>
<script src="https://js.stripe.com/v3/"></script>
</form>'."\n";

<script type="text/javascript" language="javascript">';
print '<script src="https://js.stripe.com/v3/"></script>'."\n";

// Code to ask the credit card. This use the default "API version". No way to force API version when using JS code.
print '<script type="text/javascript" language="javascript">'."\n";
?>

// Create a Stripe client.
Expand Down

0 comments on commit 8d28506

Please sign in to comment.