are you using official plugins or sefmade plugins?
the AI says you should use something like
<PLUGIN>
<DELETE>1</DELETE>
</PLUGIN>
in the xml file quote "Return an empty plugin structure when conditions are not met:"
This structure includes a <DELETE> tag with a value of 1, indicating that the existing data should be removed
In your plugin's Map.pm file, add logic to handle the deletion:
if ($xml->{PLUGIN}->{DELETE} && $xml->{PLUGIN}->{DELETE} == 1) {
# Delete existing data for this plugin
$dbh->do("DELETE FROM plugins WHERE hardware_id = ? AND name = ?", undef, $deviceId, $pluginName);
} else {
# Process normal plugin data
# ...
}
Update your cd_plugin.php file to check for the deletion flag:
if (isset($plugin_data['DELETE']) && $plugin_data['DELETE'] == 1) { // Remove the plugin data from the display continue; }
i'm sure you can hardly do anything with the ai stuff, but maybe it will give you some ideas