WC_Product::set_download_limit()
Set download limit.
Method of the class: WC_Product{}
No Hooks.
Return
null
. Nothing (null).
Usage
$WC_Product = new WC_Product(); $WC_Product->set_download_limit( $download_limit );
- $download_limit(int|string) (required)
- Product download limit.
Changelog
Since 3.0.0 | Introduced. |
WC_Product::set_download_limit() WC Product::set download limit code WC 9.7.1
public function set_download_limit( $download_limit ) { $this->set_prop( 'download_limit', -1 === (int) $download_limit || '' === $download_limit ? -1 : absint( $download_limit ) ); }