boolean IPS_DeleteMedia (integer $MediaID, boolean $DeleteFile)
MediaID | ID of the media object to be deleted |
DeleteFile | TRUE if the file should be deleted, FALSE if the file should be moved to the 'deleted' folder. |
If the command succeeds, it returns TRUE, otherwise FALSE. |
The command removes the media object with ID MediaID from the media pool.
The media object can only be deleted if it has no children.
IPS_DeleteMedia($MediaID, true);