Rocksolid Light

Welcome to Rocksolid Light

mail  files  register  newsreader  groups  login

Message-ID:  

God made the integers; all else is the work of Man. -- Kronecker


devel / comp.lang.javascript / Re: javascript variables on PayPal button

SubjectAuthor
o Re: javascript variables on PayPal buttonAce of diamonds

1
Re: javascript variables on PayPal button

<a4bd8d0c-aa00-4a55-a020-abfd3db8cdddn@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=5330&group=comp.lang.javascript#5330

  copy link   Newsgroups: comp.lang.javascript
X-Received: by 2002:a05:6214:62a:b0:472:eac1:7565 with SMTP id a10-20020a056214062a00b00472eac17565mr17259528qvx.71.1657124302136;
Wed, 06 Jul 2022 09:18:22 -0700 (PDT)
X-Received: by 2002:a05:6808:6d7:b0:325:67ff:a21b with SMTP id
m23-20020a05680806d700b0032567ffa21bmr23871224oih.105.1657124300776; Wed, 06
Jul 2022 09:18:20 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!news.misty.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.javascript
Date: Wed, 6 Jul 2022 09:18:20 -0700 (PDT)
In-Reply-To: <9a75165d-d844-4a64-bc55-83f10ac68f91n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=82.131.37.215; posting-account=HfIszAoAAAC8ch6q3uChpTWUALHCfEoF
NNTP-Posting-Host: 82.131.37.215
References: <9a75165d-d844-4a64-bc55-83f10ac68f91n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <a4bd8d0c-aa00-4a55-a020-abfd3db8cdddn@googlegroups.com>
Subject: Re: javascript variables on PayPal button
From: he12091983@gmail.com (Ace of diamonds)
Injection-Date: Wed, 06 Jul 2022 16:18:22 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Lines: 72
 by: Ace of diamonds - Wed, 6 Jul 2022 16:18 UTC

Hey guy. Would You want to get rich with me doing programming? If yes, call me !!!!!!!!!

โœ†โ˜Žโ˜๐Ÿ“ฑ๐Ÿ“ž : 372 53900660

Daniele Ferrarese kirjutas Reede, 4. mรคrts 2022 kl 16:52:27 UTC+2:
> A greeting to all participants in the NG
>
> I'm trying to insert the HTML code, from PayPal, to insert a button "bynow" on my ecommerce (see code)
>
> <div id="smart-button-container">
> <div style="text-align: center;">
> <div id="paypal-button-container"></div>
> </div>
> </div>
> <script src="https://www.paypal.com/sdk/js?client-id=my_id&enable-funding=venmo&currency=EUR" data-sdk-integration-source="button-factory"></script>
> <script>
> function initPayPalButton() {
> paypal.Buttons({
> style: {
> shape: 'rect',
> color: 'gold',
> layout: 'vertical',
> label: 'paypal',
>
> },
>
> createOrder: function(data, actions) {
> return actions.order.create({
> purchase_units: [{"description":"Order N.","amount":{"currency_code":"EUR","value":10}}]
> });
> },
>
> onApprove: function(data, actions) {
> return actions.order.capture().then(function(orderData) {
>
> // Full available details
> console.log('Capture result', orderData, JSON.stringify(orderData, null, 2));
>
> // Show a success message within this page, e.g.
> const element = document.getElementById('paypal-button-container');
> element.innerHTML = '';
> element.innerHTML = '<h3>Thank you for your payment!</h3>';
>
> // Or go to another URL: actions.redirect('thank_you.html');
>
> });
> },
>
> onError: function(err) {
> console.log(err);
> }
> }).render('#paypal-button-container');
> }
> initPayPalButton();
> </script>
>
> trying to replace "description:Order N." with a variable $_SESSION['customer_id'], and total EUR 10 with variable $_SESSION['total_order'] already in my checkout page. I'm not able to find the right syntax.
> Besides I would like, if payment success, activate function "validateForm()" which is sending all records to database.
>
>
> Thank you for help.
> Rgds.
> Daniele

1
server_pubkey.txt

rocksolid light 0.9.81
clearnet tor