edd_is_discount_used( string $code = null, string $user = '', int $code_id, bool $set_error = true )

Checks to see if a user has already used a discount.


Description Description


Parameters Parameters

$code

(Optional) Discount Code.

Default value: null

$user

(Optional) User info.

Default value: ''

$code_id

(Required) Discount ID.

$set_error

(Optional) Whether an error message be set in session

Default value: true


Top ↑

Return Return

(bool) $return Whether the the discount code is used.


Top ↑

Source Source

File: includes/discount-functions.php


			

Top ↑

Changelog Changelog

Changelog
Version Description
2.7 Updated to use EDD_Discount object.
1.5 Added $code_id parameter.
1.1.5 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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