edd_update_discount_status( int $code_id, string $new_status = 'active' )

Updates a discount’s status from one status to another.


Description Description


Parameters Parameters

$code_id

(Required) Discount ID (default: 0)

$new_status

(Optional) New status (default: active)

Default value: 'active'


Top ↑

Return Return

(bool) Whether the status has been updated or not.


Top ↑

Source Source

File: includes/discount-functions.php


			

Top ↑

Changelog Changelog

Changelog
Version Description
2.7 Updated to use EDD_Discount object.
1.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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