Autoloading Example

To autoload a checkout once a page loads, add an element containing id="ps_checkout_load". Most attributes that are available to be added to buttons can also be added to the autoload element. Upon a page loading, a checkout will render with the configuration specified on the autoload element.

<div id="ps_container_id"></div>

<div
  id="ps_checkout_load"
  ps-mode="embed"
></div>

<script
  type="text/javascript"
  id="ps_checkout"
  src="https://checkout.paystand.co/v4/js/paystand.checkout.js"
  ps-env="sandbox"
  ps-publishableKey="1noqhele1yjgieoi8aqe4n8i"
  ps-containerId="ps_container_id"
  ps-checkoutType="checkout_payment"
></script>

📘

Autoloading Embed vs Modal Checkout

Though the main use case for the Autoloading feature is an embedded checkout, which you most likely would like to show up immediately when the page loads, it can also be used in modal mode. The autoloading modal experience is similar a browser application printer dialog when it generates an HTML or PDF to print in a different tab or window.