llms_setup_pending_order( array $data = array() )

Setup a pending order which can be passed to an LLMS_Payment_Gateway for processing.


Description Description


Parameters Parameters

$data

(Optional) Data used to create a pending order.

  • 'plan_id'
    (int) (Required) LLMS_Access_Plan ID.
  • 'customer'
    (array) (Required). Array of customer information formatted to be passed to LLMS_Person_Handler::update() or llms_register_user()
  • 'agree_to_terms'
    (string) (Required if llms_are_terms_and_conditions_required() are required) If terms & conditions are required this should be "yes" for agreement.
  • 'payment_gateway'
    (string) (Optional) ID of a registered LLMS_Payment_Gateway which will be used to process the order.
  • 'coupon_code'
    (string) (Optional) Coupon code to be applied to the order.

Default value: array()


Top ↑

Return Return

(array)


Top ↑

Source Source

File: includes/functions/llms.functions.order.php


			

Top ↑

Changelog Changelog

Changelog
Version Description
5.0.0 Use llms_update_user() instead of deprecated LLMS_Person_Handler::update().
4.21.1 Sanitize coupon code prior to outputting it in error messages.
4.2.0 Prevent double displaying a notice to already enrolled students in the product being purchased.
3.29.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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