Deletes an existing membership level.
Parameters
- level_id (int) – The ID of the level to delete
Return
Returns a multi-dimensional array containing the operation status and an array of remaining membership levels.
Example Code
<?php $level = wlmapi_delete_level(1344363854); print_r($level); ?>
Example Output
Array ( [success] => 1 [levels] => Array ( [level] => Array ( [0] => Array ( [id] => 1340726008 [name] => Test Level 1 [_more_] => /levels/1340726008 ) [1] => Array ( [id] => 1340896239 [name] => Test Level 2 [_more_] => /levels/1340896239 ) [2] => Array ( [id] => 1340896250 [name] => Test Level 3 [_more_] => /levels/1340896250 ) ) ) [supported_verbs] => Array ( [0] => GET [1] => POST ) )
Notes
This functions returns WLMAPIMethods::delete_level($level_id) in core/api-helper/class-api-methods.php