CheckoutChamp
Submit TicketStatus
  • CheckoutChamp
  • Funnel Builder
    • Onboarding & Activation
      • Go Live Checklist
    • Dashboard Overview (APP)
    • Creating & Editing Funnels/Pages
      • Funnel Visualizer and Page Builder
        • Funnel Visualizer
          • Page Types
          • Connecting Funnel Pages
            • Route An Arrow For New And Repeat Customers
          • Edit Funnel Settings
            • Tracking Pixels
            • Offers and Upsells
            • Collections
            • Coupons
            • Configure Google Analytics
            • Gateways
            • Affiliates
              • Everflow
            • Sales Tax Profiles
            • Add Ons
              • PAAY Add On
              • Route Add On
              • ShipEngine Add On
              • Google Places
              • Fraud Manager Add On
              • Facebook Messenger
              • reCAPTCHA Enterprise
            • SMTP Accounts
            • Fulfillment Houses
            • Ship Profiles
            • Fonts
            • Payments
              • Affirm
              • Afterpay
              • Amazon Pay
              • Apple Pay
                • Legacy Apple Pay Setup (Apple Pay Plugin)
              • Multi-Pay Rebills
              • BitPay
              • Bancontact
              • BLIK
              • Boleto
              • Google Pay
              • iDEAL
              • Klarna
              • P24
              • PayPal Seamless Checkout
                • Fastlane
              • SEPA
              • Sezzle
              • TWINT
            • Social Proof
            • Maintenance
          • URL Customization
          • Page Templates
        • Page Builder
          • Builder Toolbar
            • Device View Changer
            • Popups
          • Style Manager
          • Layer Manager
            • Hiding and Revealing Elements
          • Building Blocks
            • Basic Blocks
              • Rows & Columns
            • Form Blocks
              • Shopping Cart Element
            • Button Blocks
              • Button & Link Actions
            • Product Blocks
            • Carousel / Slider Blocks
            • Icon Blocks
            • Social Media Blocks
            • Testimonial Blocks
            • Extra Blocks
            • My Element Blocks
        • 🆕Page Builder 2.0
          • 📰New Features!
          • Builder Toolbar
            • Device View Changer
            • Popups
          • Settings & Style Manager
          • Layer Manager
            • Hiding and Revealing Elements
          • Building Blocks
            • Basic Blocks
              • Rows & Columns
            • Form Blocks
              • Shopping Cart Element
            • Button Blocks
              • Button & Link Actions
            • Product Blocks
            • Extra Blocks
              • Bullet List
              • Progress Bar
              • Collapsible List / FAQ Section
              • Testimonial Blocks
              • Carousel / Slider Blocks
              • Survey
              • Timer
            • My Element Blocks
          • Page Building Tips
            • Using Shopify information on a Thank You page
            • Placeholders and Input Formats
            • Hide element if box is checked/ Billing address same as Shipping
            • How to set Anchor Links
            • How to convert a button into a link
            • Adding Age Consent
            • Creating a Split Variation
            • Subscribe & Save
            • Tokens
            • Redirect from CheckoutChamp to externally hosted upsell or Thank You page
            • Duplicate Input Indicator
            • Product Quantity Select
            • Make a button appear after a set amount of time
            • Making A New Section Appear After a Timer Expires
            • Timer - Route to next page
            • Use link or button to initiate a pop-up
            • Convert Checkbox and Radio
            • Lazy Loading
            • Element Toolbar
            • Applying custom fields to inputs
            • Shipping Profiles
            • Duplicating Pages & Funnels
            • Bootstrap Integration
            • Customer File Uploads
            • Product Tiles
            • Variant Selection
              • Product Variant Selection
              • Customized Variant Bundles (Single Variant)
              • Product Checkbox
            • Product Table
            • Hover Effects (adding Pseudo-classes)
            • Page Sizes and Image Dimensions
            • Flex Settings
            • Using the Survey Element
            • Custom Classes
            • Creating a Marketing Opt-in Checkbox
            • Common Page Elements
            • Create a Common Menu
            • Currency Selector
            • Acquire and Send Session Data to 3rd Party
            • Language Replacement Mapping
            • "Upgrade" or Replace a Product
            • Pass custom parameter on URL and store onto order
            • Product Drop Down / Select
            • Genders
            • Keep customers on Upsell Page after buying an upsell
            • Dynamic Order Bumps
            • Dynamic Upsells
            • Main Site Color
      • Adding Local HTML Files
      • Domain Configuration
        • Domain Trouble Shooting
        • DNS Troubleshooting Guide
        • Redirecting your Root (Apex) Domain
        • GDPR by Clym
      • Publishing a Funnel
      • Basic SEO
    • Redirect Storefront to CheckoutChamp
      • BigCommerce Plugin
        • BigCommerce Checkout Redirect
        • Recurring Products
      • WooCommerce Plugin
        • WooCommerce Checkout Redirect
      • Magento Plugin
      • Redirect external funnel to CheckoutChamp Checkout
      • Using Google Analytics with Redirect
    • Customer/Membership Portal
      • Customer Portal (Without Plugin)
      • Membership Portal with CustomClub Plugin
      • SSO with External Sites
    • Account Settings
      • Domain Forwarding
    • Analytics Definitions
  • CRM
    • Getting Started in your CRM!
    • CRM Dashboard
    • CRM Account Settings
      • Fraud Protection
      • CRM Subscription Page
      • Enable Automatic Cancel on Refund and Void
      • Staggered Rebills
    • Customer Section
      • Customer Service
        • Customer Service Tutorial
        • Locate a Customer Record
        • Continuity Purchase Profile
        • Refund/Void a Transaction
        • Cancel an Order
        • Cancel or Pause a Subscription
        • Restart a Subscription
        • C/S Fulfillment Actions
        • Resend emails to customers
        • Rerun a Declined New Sale
        • Merge Existing Customers
      • Order Entry
      • Fulfillment
      • Quality Assurance
    • CRM Setup
      • Product Setup
        • Product Creation
        • Product Variations
          • Variant Bundles
      • Campaign Setup
        • Creating a Campaign
        • Campaign Categories
        • Campaign Types
        • Adding a Product to a Campaign
          • Common Offer Setups
            • T-Shirt Club
        • Auto-Responder Setup
          • Autoresponder Date Formats
        • Shipping Profiles
        • Taxes
        • Campaign Coupons
        • Custom Fields
        • Adding C.O.D. to Campaigns
        • Single Transaction Orders
        • Multi-Currency
      • Call Center Setup
        • Adding and Editing Call Centers
        • Adding Call Center Agents
        • Setting Call Center Commissions
        • Batch Update Call Center Source Values
        • Cancellation Reasons, Refund Reasons, and Call Dispositions
      • Affiliate Setup
        • Adding and Editing Affiliates
        • Affiliate Tracking Link/String
        • Affiliate Pixels
          • Testing and Troubleshooting CPA Pixels
          • Testing CPC Pixels
        • Affiliate Commissions
        • Setting up an Affiliate User
        • Batch Update Affiliate Source Values
        • General External Affiliate Software/Network Setup
        • Facebook Pixel Setup (Direct API)
    • Fulfillment Section
      • Add and Editing Fulfillment House
      • Fulfillment Batch Update
      • Fulfillment Summary Report
      • Bundle Fulfillment
      • Fulfillment Statuses
      • Testing Fulfillment through Order Entry
      • Cash on Delivery setup
        • C.O.D. Order Entry Option
      • Upload Returned Orders
      • Edit Fulfillment Items
      • Fulfillment Inventory
      • Shipping Validation
    • Gateway Setup
      • Gateway List
      • Adding a Gateway
        • Testing Your Gateway Through Order Entry
      • Gateway Integrations
        • Adyen
        • Adyen V2
          • Klarna on AdyenV2
          • PayByBank on AdyenV2
          • Afterpay on AdyenV2
        • Affirm
        • Afterpay
        • Airwallex
          • Airwallex - Alternate Payments
        • Amazon Pay API Integration
        • Apple Pay
        • Authorize.net
        • Bank of America
        • BitPay
        • Braintree
        • Cardinity
        • Cardstream
          • Cardstream - Alternate Payments
        • Celerispay
        • Centrobill
        • Checkout.com
          • Checkout.com - Alternate Payments
        • Corefy
        • Easytransac
        • eMerchantPay V3
          • eMerchantPay - Alternate Payments
        • Everyware
        • Fat Zebra
        • FibonatixV2
        • FlexFactor
        • Gala Technology
          • Gala Technology - Alternate Payments
        • Google Pay API
        • HiPay 3DS
        • Innova
        • iyzico
        • Klarna
        • MARKETFLOW
        • Maverick
        • Merchant Warrior
        • MojoPay
        • Mollie
        • Moonlight Payments
        • MuchBetter
        • MyCPO
        • NMI
          • NMI - useCustomerVault Configuration
        • NomuPay
          • NomuPay - Alternate Payments
          • Klarna on NomuPay
        • OpenPath
          • IoniaPay Instant Direct Payments (OpenPath)
        • PagBrasil
        • Pathly
        • Pay.com
        • PAY.ON
        • Payex-GreenMoney
        • PayGate
        • Paynetworx
        • PayPal Commerce Checkout
          • PayPal Commerce Checkout (Direct API)
          • PayPal Commerce Checkout (Legacy)
            • PayPal Seamless Checkout - 2-Click Upsells (without Reference Transactions)
          • PayPal Commerce Checkout (SDK)
        • Paysafe V2
        • Paystrax
        • PayXpert 3DS V2
        • Pixxles
        • Poynt
        • Priority Payments
        • Quaife
        • Quantum
        • QuickPay
        • Radom
        • RocketGate
        • SafeCharge
        • Sezzle
        • Skrill
        • Solid
        • Splitit
        • Square Payments
          • Square Payments V2 (Checkout Champ builder set-up)
        • Stripe
          • Stripe - Alternate Payments
          • Klarna on Stripe
        • SurePay
        • TruCommerce
        • Trust Payments
          • Trust Payments - Alternate Payments
        • TRX
        • UrPay
        • Vantiv
        • WAAVE
        • WEBPAY
        • WhiteLabel (WL) Payments
        • WithReach
        • WorldLine (Bambora)
        • Worldline V2
          • Worldline V2 - Alternate Payments
        • Worldnet
        • Worldpay
      • Advanced Transaction Routing Interface (ATRI)
        • ATRI Algorithms
        • Cascade Profiles
        • ATRI Settings and Notifications
      • Recycle Billing
      • Standard BIN Mapping
      • PrePaid BIN Mapping
      • Decline Message Mapping
      • Dynamic Descriptors
      • RDR
      • Ethoca Refunds
      • Direct API 3DS Instructions
      • dLocal Properties
      • Zero dollar card verification
    • Reports
      • Customer Reports
        • Order Summary
        • Order Details
          • Order Statuses
        • Cancellation Report
        • Retention Report
        • Revenue Summary
        • Customer Details Report
      • Payment Reports
        • Transaction Summary Report
        • Transaction Details Report
        • Account Updater
        • Card Processing
        • Refund Details
        • Chargeback Details
        • Billing Report
        • Projected Billing
        • Sales Tax
      • Gateway Reports
        • Reserve Report
      • Sale Reports
        • Continuity Report
          • Continuity Purchase Statuses
        • Affiliate Report
      • Call Center Reports
        • Customer Service Report
      • Fulfillment Reports
        • Fulfillment Details
      • UTM Filters
      • Key Performance Indicators - KPIs
    • Admin Setup
      • Plugin Setup
      • Create a User
        • Create an Affiliate User
        • Create An API User
        • Leads Agents
      • Import
        • Import Coupons
      • Export Webhook Profiles
        • Postback Export Profiles
        • FTP Export Profile
        • Export Webhook Field Mapping Options
      • Blacklist
      • Event Logs
      • Test Cards
      • Legacy Data Import
        • CheckoutChamp PGP Encryption Procedures
        • Migrating Data From a Processor To Checkout Champ
    • Plugins
      • Accounting
        • QuickBooks Online Plugin
      • Affiliate Systems
        • Everflow Integration
        • Trackfiliates
      • Analytics and Reporting
        • Wicked Reports
      • Authentication
        • PAAY
          • Authenticating with PAAY 3DS on Landers
        • PAAY 3RI
      • Chargeback Management
        • Fraud Deflect
        • Ethoca
        • Midigator
        • Optimal Alerts
        • ChargebackHelp
      • Data Sources
        • Big Commerce
          • BigCommerce Checkout Redirect
        • Smarty
        • ClickBank
        • Facebook Marketplace
        • FFL Scope
        • FluidPay Account Updater
        • Google Shopping
        • Gorgias
        • HubSpot
        • Listrak
        • OpenBorder
        • Paperform
        • Re:amaze
        • Recharge
        • ShipEngine
        • Shopify
          • Use Shopify Products Without Shopify Redirect
          • Octane AI
        • Triple Whale
        • WooCommerce
          • Using WooCommerce Catalog with Checkout Page
        • Zapier
        • Zendesk
        • DataDojo
        • ViralSweep
      • Debt Collection
      • Email Service Providers
        • Email Service Provider Plugins
        • Email Service Provider General Set Up
        • Active Campaign Deep Integration
        • InboxFirst
        • Klaviyo
        • Constant Contact
        • SendLane
        • Infusionsoft/Keap
        • Sendgrid
        • Ontraport
        • TxtFlo
        • Postscript
        • Maropost
        • Mailchimp
        • ConvertKit
        • Attentive
      • Express Consent
        • Expressed Consent
        • Expressed Consent CRM Configuration
        • Expressed Consent Guidelines
      • FlexPay
      • Fraud Services
        • Fraud Manager
        • Kount Enterprise
        • Device Data Collector Pixel (DDC Pixel)
        • IPQS
        • NoFraud
      • Fulfillment Houses
        • General Fulfillment House Setup
        • AliExpress
        • Amware
        • CJ Dropshipping
        • DesktopShipper
        • FTP Fulfillment Option
        • Fulfillment by Amazon
        • mintsoft
        • ShipBob
        • Shiphero
        • ShipStation
        • Save Rack
        • Store Pickup
        • Pharmacy Hub
        • Promise Pharmacy
      • Identity Verification
        • 1account
        • AgeChecker.net
        • ID.me
      • IVR Systems
      • List Management Services
        • Red Crane Media
        • Sociallity
      • Membership Services
        • Circle.so Webhook Guide
        • General Membership Club Plugin Setup
        • CustomClub
        • MemberMouse
        • Kajabi Webhook Guide
      • Phone Switches
        • ViciDial
        • Ytel
        • Five9 Sales Agent Call Pop
      • Rewards
        • LoyaltyLion
        • Stamped
      • RMA Services
      • Sales Call Tracking Services
      • Shipping Services
        • InsureShip
        • Route
      • SMS
        • ClickSend (Data Shuttle)
        • Twilio SMS Setup
        • SendPlex SMS Plugin
      • SMTP Maintenance
        • SMTP Maintenance Setup
        • Sendgrid SMTP Profile
        • Maropost SMTP Profile
        • Gmail SMTP Profile
      • Tax Services
        • Avalara Tax
          • Enabling and Setting Up the Avalara AvaTax Plugin
          • Add Avalara Tax to a Campaign
          • Add Tax Code to Products
          • Add Freight Tax to Shipping
          • Avalara Tax - Order Entry
        • Interpayments
        • TaxJar
          • Add TaxJar to Campaigns
          • Add Tax Code to Products
          • Add Freight Tax Code to Shipping
          • TaxJar Address Verification- Customer Service/ Order Entry
          • TaxJar Support Page
      • Telehealth
        • Beluga EHR
      • Upsell
        • Integrated Upsell Program
    • Frequently Asked Questions (FAQS)
      • General CRM Questions
      • Order Processing Questions
      • Fulfillment Questions
      • Reporting Questions
      • Affiliate Tracking Questions
      • Developer Questions
      • Builder Questions
      • How-to articles
        • Force Bill a Purchase
        • Submit a Support Ticket
    • Click-to-Cancel
  • API Documentation
    • API Documentation
      • Recommended API Flow
      • Performing API Calls
  • Policies
    • EULA
    • Privacy Policy
    • Acceptable Use Policy
    • Billing Policy
    • GDPR
    • A-C&B
Powered by GitBook
LogoLogo

CheckoutChamp Links

  • Website Builder
  • CRM
  • Status
  • Need more help?

Refer a Friend

  • Referral Program

No account yet?

  • Schedule Sales Demo
On this page
  • Assumptions
  • Login (when Shopping site is on a different root domain)
  • Logout (when Shopping site is on a different root domain)
  • Login (when Shopping site is on same root domain)
  • Logout (when Shopping site is on same root domain)
  1. Funnel Builder
  2. Customer/Membership Portal

SSO with External Sites

PreviousMembership Portal with CustomClub PluginNextAccount Settings

Last updated 8 months ago

It is possible to create a site outside of CheckoutChamp that has login capability to a Membership Portal within CheckoutChamp. Any user that logs in will remain logged in when navigating between the sites. The user may also checkout using their card on file.


Assumptions

This document is for developers attempting to link a non-CheckoutChamp site (“Shopping”) and a CheckoutChamp site (“Checkout”) with a single sign-on. A returning consumer can login on the Shopping site and remain logged in as they navigate between Shopping, Checkout, and Membership sites.

There are 3 sites available

  1. A Shopping site (not in CheckoutChamp)

  2. A Checkout site (in CheckoutChamp)

  3. A Membership login page (in CheckoutChamp). This can be part of a larger , but it can also be only a login page.

These sites can be on the same or different root domain. Checkout and Membership pages can be in the same funnel within CheckoutChamp. If they are in different funnels those funnels must use the same root domain but can use different subdomains.

Login (when Shopping site is on a different root domain)

Login adds a cookie to the Membership site root domain. That cookie contains an access token that expires in 24 hours. Members must login again after 24 hours. Since the Checkout site and Membership site have the same root domain, they will share cookies and will be automatically logged in. Since the Shopping site is on a different root domain, it needs to include an iframe to the Membership site to read the cookie.

Steps to activate login:

  1. Place some kind of Login option on the Shopping site. When the Login option is chosen, redirect the user to the CheckoutChamp membership login page. The proper redirect format is https://www.membership.com/login?redirectToMe=https://www.shoppingsite.com/home

    • “www.membership.com/login” is the CheckoutChamp login page URL

    • “https://www.shoppingsite.com/home” is the Shopping site page where the user is to be returned after successful login

  2. Place the following script into the body of all pages in the Shopping site

    <script>
    var membershipdomain = "https://www.membership.com";
    var shoppingdomain = "https://www.shoppingsite.com";
    var ifrm = document.createElement("iframe");
    ifrm.setAttribute("id", "ifmcrossoriginid");
    ifrm.setAttribute("name", "ifmcrossorigin");
    ifrm.setAttribute("src", membershipdomain + "/iframe.html?shoppingdomain=" + shoppingdomain);
    ifrm.setAttribute("class", "btn-primary");
    ifrm.style.width = "109px";
    ifrm.style.height = "36px";
    ifrm.style.border = "none";
    if(!navigator.userAgent.includes("Chrome") && navigator.userAgent.includes("Safari") && document.referrer === membershipdomain){
      ifrm.style.display = "block";
      document.getElementById("modal_request_access").appendChild(ifrm);
    } else {
      ifrm.style.display = "none";
      document.body.appendChild(ifrm);
    }
    window.addEventListener("message", (event) => {
      if (event.origin !== membershipdomain)
        return;
      if(event.data == "logoutSuccess") {
        //write code to clear all the session information in your application
      }
      // This event.data will have the first name and the last name.
      console.log(event.data);
    }
    , false);
    function logoutMembership(){
      var iframe = document.getElementById('ifmcrossoriginid');
      var win;
      try { 
        win = iframe.contentWindow;}
      catch(e) { win = iframe.contentWindow;}
      win.postMessage("logout", membershipdomain);
    }
    </script>
  3. Edit the script and page as follows:

    • Set the membershipdomain variable on line 2 to your Checkout domain. This should be the domain only, not a specific page.

    • Set the shoppingdomain variable on line 3 to your Shopping domain. This should be the domain only, not a specific page.

    • For Chrome, Firefox, and Edge browsers, line 23 displays the returned value from the login event. The line can be removed. It is listed here as an starting point to display login information on the Shopping site, such as a first and last name. This is optional.

    • Safari browsers require user acceptance of the SSO cookie

      • Add a modal form to the Shopping site. The screenshot below is an example.

      • Inside the modal window, create a container section to display buttons. In the screenshot example, the id of this container is “modal_request_access“. Be sure the id given for the container matches line 14 in the body script.

      • After login the container will be used by the script iframe to display an ‘Allow Access’ button.

      • Once the user clicks the 'Allow Access’ button, the Safari browser will prompt the user to allow access to read the Membership domain storage. Once the user allows that, line number 23 will have the user data.

Logout (when Shopping site is on a different root domain)

The script in the Login section contains a logoutMembership() function. Call this function when the user logs out. The user will be logged out from both the Shopping site and Checkout site. It is advised to also remove any login information that you previously saved in the browser, such as user first and last name.

Login (when Shopping site is on same root domain)

Login adds a cookie to the root domain. That cookie contains an access token that expires in 24 hours. Members must login again after 24 hours. Since all the sites have the same root domain, they will share cookies and will be automatically logged in.

  1. Place some kind of Login option on the Shopping site. When the Login option is chosen, redirect the user to the CheckoutChamp membership login page. The proper redirect format is https://member.shoppingsite.com/login?redirectToMe=https://www.shoppingsite.com/home

    • “member.shoppingsite.com/login” is the CheckoutChamp login page URL

    • “https://www.shoppingsite.com/home” is the Shopping site page where the user is to be returned after successful login

  2. Once the user is redirected back to the shopping site, access document.cookie to read the user information. You can also add the following script to read the cookie and add it as a separate javascript objects.

const cookieData = {};
if (document.cookie) {
    var cookies = document.cookie.split(";")
    cookies.forEach(function (d) {
        var cookieName = d.split("=")[0].trim();
        var cookieVal = d.split("=")[1].trim();
        if (cookieVal) {
            cookieData[cookieName] = cookieVal;
        }
    })
}

Logout (when Shopping site is on same root domain)

Add the following script to the Shopping site. Execute clearCookies() when the user logs out. If you wish to keep some cookies specific to the Shopping site, then rewrite clearCookies() to retain the desired cookies.

function clearCookies() {
    const cookies = document.cookie.split("; ");
    cookies.forEach((cookie) => {
        const name = cookie.split("=")[0];
        if (name) {
            setCookie(name, "", false);
        }
    });
    document.cookie = "";
}
function setCookie(name, value, allowCrossOrigin){
    var sameSite = allowCrossOrigin ? "; SameSite=None; Secure" : ";";
    document.cookie = name + "=" + value + "; domain=" + document.domain.split('.').reverse().splice(0,2).reverse().join('.') +  sameSite;    
}
Membership Portal
Assumptions
Login (when Shopping site is on a different root domain)
Logout (when Shopping site is on a different root domain)
Login (when Shopping site is on same root domain)
Logout (when Shopping site is on same root domain)