The vae_store_checkout() function completes the checkout action for the current website user. This function should be called after vae_store_register() in a PHP-based checkout flow.


vae_store_checkout($options = array())

  • $options - PHP associative array containing the information needed for checkout This field accepts the same named inputs as the form elements that go inside the <v:store:checkout> tag. We also list them in the next section.

Accepted Options

These are options that may be provided in the $options array.

  • cc_type - type of credit card being used. Format should be that returned by <v:store:credit_card_select>. The options are visa, master, discover, america_express, switch, and solo.

  • cc_number - credit card number.

  • cc_month - credit card expiration date (month). Format: 2 digit month (01-12).

  • cc_year - credit card expiration date (year). Format: 4 digit year (i.e. 2010).

  • cc_cvv - credit card verification value.

  • email_confirmation - path to the HTML template to use for the confirmation E-Mail sent to the customer.

  • email_received - path to the HTML template to use for the order received E-Mail sent to the merchant.

  • email_shipping - path to the HTML template to use for the order shipped E-Mail sent to the customer.

  • gateway_transaction_id - If you want to process the payment yourself, rather than having Vae integrate with your merchant gateway, pass the completed transaction ID here.

  • notes - any user-provided notes that go along with the transaction. These will be logged in the Vae backstage for the merchant to see.

  • packing_slip - path to the HTML template to use for the packing slip generated in the backstage.

  • payment_method - payment method to use. Defaults to the first available payment method on your website. This should be the same string returned as the option value in a <v:store:payment_methods_select> tag.

  • shop_page - users will be redirected to this page if their cart doesn’t have any items in it.

  • store_logo - Full URL to logo to be used on the Invoice/Packing slip.

  • store_name - Store name to be used on the Invoice/Packing slip. Useful if you are maintaining multiple store brands through the same Vae account.

  • stored_payment_method - If set, will try to use a previously stored payment method for the current customer.

  • subscription_name - Name to use for the subscription.

  • subscription_amount - Amount to charge per subscription period.

  • subscription_days - Days per subscription period.

  • subscription_description - Description of the goods or services provided by the subscription.

  • subscription_status - Set to 1 if this transaction should be marked as the initial transaction in a recurring subscription. This is primarily used for reporting purposes, and may be used independently of the other subscription options above.


Returns true on success and false on failure.

Sample Usage

// checkout a user          
  'store_name' => "My Store",
  'gateway_transaction_id' => "12345"