magento2 – Magento 2: I need to implement google captcha on checkout page(card payments)

I need to implement a google captcha on the checkout page(for card payments).
I am having payment transaction failures with fraudulent orders being placed on the website.
Anyone have solutions for the same.
I have searched on google but didn’t get any solutions.
There are so many extensions for captcha but not providing the checkout captcha.

If anyone has any idea about Custom functionality that will also work for me.

Please help with the same.

Thanks!!

php – How to save custom Session variable till the checkout page?

I am trying to save a session variable based on a query parameter.
Example – https://ferroglan.com/cover-search-result/?swoof=1&maker=a3

I want to save maker=value throughout the single session until the browser is closed or the search parameter changes.

What I have achieved so far is that on the result page I can see the value of maker in my variable.
session variable

But as soon as I move to the product page it doesn’t stay even though code is present on the head tag.

Q. How do I save it on the product page as a custom variable and then till the checkout so that when someone places the order I can know which model the user has selected in the Admin dashboard.

// Get query parameter 

  add_action('init', 'session_maker');
  function session_maker()
  {
          session_start();
    if(isset($_GET('maker')))
    {   
        $_SESSION('maker') = $_GET('maker');
        echo $_SESSION('maker');
    }
    
  } 

I know to add the custom field to the woo-commerce checkout but mainly I want to understand how can I save this variable value to the product page.

magento2 – Take recurring subscription payments via Guest checkout – Magento 2

We have a client who is keen to take recurring payments BUT only allows guest checkouts

They ideally wanted to use Braintree, but it seems the Braintree recurring payment extension only works with customers either logging in to or creating an account (which for conversion optimisation reasons, the client doesn’t want)

Does anyone know of any extensions that will allow recurring payments AND guest checkout in Magento 2? Ones that work with Braintree would be preferable, but at this point I’ll take any payment processor

Thanks

magento2.3.3 – Magento 2: Custom Validation with Email field in checkout

I need to verify the entered email address in checkout against the API response. So I’m thinking to add the custom validation field with the email in checkout.

Here I will check the API response.
http://127.0.0.1/magento2/V1/customers/isEmailAvailable

If the email is invalid I need to trigger the custom validation rule.

Please give me some suggestion

magento2 – Magento 2 Checkout show Order Summary in popup div window

Good Afternoon All,

I am currently working on a small module that requires a copy of the Order summary is shown in a pop-up window after the checkout has loaded.

I have been working with the data-bind=”afterrender: myFunctionCall” and have tried this at the summary level, side-bar level and the item render loop level to see if I could pop the information in a div. The problem I am facing is that the items are still being loaded after the fact and therefore I do not have all the information.

I was wondering if anyone has a solution for the detection of when the checkout page has loaded or if there is a better approach for this.

Any help and guidance would be very welcome.

8 – How do I get the order_id and order_number on the checkout completed page?

I’m trying to get the order information inside the mymodule_preprocess_page hook.

On the normal page I can get it via the $cart. But the $cart is not available on the checkout page anymore. How do I get the order information specifically the order_id and order_number.

This is what I do on other pages:

  $order_type = 'physical';
  $cart_provider = Drupal::service('commerce_cart.cart_provider');
  $store = Drupal::service('commerce_store.current_store')->getStore();
  $cart = $cart_provider->getCart($order_type, $store);
  if ($cart) {
    foreach ($cart->getItems() as $order_item) {
      $orderId = $order_item->get('purchased_entity')(0)->get('target_id')->getValue();
  }

checkout payment page on loading process then close Paypal window magento 2.4.1

please help me to find out this solution
checkout payment page on loading process then close Paypal window magento 2.4.1

Country name missing magento 2 checkout page billing address section

Country name is missing on magento 2 checkout page billing address section
can anyone know the solution of this issue magento version is 2.3.5

enter image description here

magento2 – Call to checkout URL redirecting to homepage

When adding a redirect to the checkout page in an Ajax done callback function, it seems to just go straight to the homepage instead:

}).done(function (data) {
    if (data.error) {
        console.log(data.error);
    } else if (data.success) {
        // take user to checkout if successful
        window.location = '<?= $this->getUrl("checkout", ("productid" => $this->getRequest()->getParam("productid"))); ?>';
    }
});

The thing is, this works as expected on a local environment and takes me to the checkout and I can access the productid parameter from there etc. but for some reason, on the release server it goes straight to the homepage.
The annoying thing is, there is nothing being reported in the server logs either so there is nothing to go off here.

Has anyone else came across this scenario before? and if so, how did you resolve it? 🙂

Cheers everyone!

Magento2 Ajax change store currency and refresh total on Checkout page while change address

I want to change the current store currency by ajax and refresh the total when changing the address on the checkout page. I have successfully changed store currency by below code:

$this->storeManager->getStore()->setCurrentCurrencyCode($currencyCode);

But problem is that when I am trying to refresh the total then the amount converted as per currency successfully but the currency symbol not changed. Below is the js code of refresh total:

cartCache.set('totals',null);
defaultTotal.estimateTotals();