Amp_Cart_Actions

Summary

Amp_Cart_Actions class


Source

File: src/BigCommerce/Templates/Amp_Cart_Actions.php

class Amp_Cart_Actions extends Cart_Actions {
	const CHECKOUT_URL = 'checkout_url';

	protected function parse_options( array $options ) {
		$defaults = [
			self::CHECKOUT_URL => home_url(),
		];

		return wp_parse_args( $options, $defaults );
	}

	public function get_data() {
		return [
			self::CHECKOUT_URL => home_url( sprintf( '/bigcommerce/%s', Amp_Cart::CHECKOUT_REDIRECT_ACTION ) ),
		];
	}
}

Methods


User Contributed Notes

You must log in before being able to contribute a note or feedback.