本文整理汇总了PHP中Asset_host::delete_icon方法的典型用法代码示例。如果您正苦于以下问题:PHP Asset_host::delete_icon方法的具体用法?PHP Asset_host::delete_icon怎么用?PHP Asset_host::delete_icon使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Asset_host
的用法示例。
在下文中一共展示了Asset_host::delete_icon方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: _
$data['data'] = _('Error! Host could not be deleted:') . ' ' . $e->getMessage();
}
}
break;
case 'remove_icon':
$validate = array('asset_id' => array('validation' => 'OSS_HEX', 'e_message' => 'illegal:' . _('Host ID')));
$host_id = POST('asset_id');
$validation_errors = validate_form_fields('POST', $validate);
if (is_array($validation_errors) && !empty($validation_errors)) {
$data['status'] = 'error';
$data['data'] = _('Error! Host ID not allowed. Icon could not be removed');
} else {
try {
$db = new ossim_db();
$conn = $db->connect();
Asset_host::delete_icon($conn, $host_id);
$db->close();
$data['status'] = 'OK';
$data['data'] = _('Host icon removed successfully');
} catch (Exception $e) {
$data['status'] = 'error';
$data['data'] = _('Error! Host icon could not be removed');
}
}
break;
case 'toggle_a_monitoring':
//Error counter
$e_counter = 0;
//Services
$services = base64_decode(POST('services'));
$services = json_decode($services, TRUE);