Skip to content

Latest commit

 

History

History
 
 

plugins

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
Put your custom RackTables add-ons into this folder.

Old local.php file is the sample of such add-ons and should be put here
to continue working.

Files should be named with .php extension to be loaded automatically.
Files are loaded in alphabetical order.

It is recommended to override existing tabhandlers and ophandlers using
registerTabHandler and registerOpHandler functions, respectively.
This is preferred over overwriting of items in $tabhandler and $ophandler,
because allows overriding the same tab or operation in multiple plugins.

Consider the following sample:

<?php

registerTabHandler ('object', 'default', 'renderObject_add_FQDN_warning');

function renderObject_add_FQDN_warning ($object_id)
{
	$object = spotEntity ('object', $object_id);
	$attrs = getAttrValues ($object_id);
	$fqdn = @$attrs[3]['value'];
	if
	(
		considerGivenConstraint ($object, '{server} and not {offline}') &&
		$fqdn == ''
	)
		showWarning ("Please set FQDN for this server");
}

?>