Open the
setup.php
file from Example 3.Go to the
cbEnhancedInfo_tree_after
function.Search for the following code:
/* Example 3 - Data retrieval is missing here ---> */ /* <--- */
Between these two lines, enter the following code:
// Retrieve the enhanced information for that host from the table $host_longitude = db_fetch_cell(" SELECT longitude FROM plugin_cbEnhancedInfo_dataTable WHERE hostId=$host_leaf_id"); $host_latitude = db_fetch_cell(" SELECT latitude FROM plugin_cbEnhancedInfo_dataTable WHERE hostId=$host_leaf_id"); $host_contactAddress = db_fetch_cell(" SELECT contactAddress FROM plugin_cbEnhancedInfo_dataTable WHERE hostId=$host_leaf_id"); $host_additionalInformation = db_fetch_cell(" SELECT additionalInformation FROM plugin_cbEnhancedInfo_dataTable WHERE hostId=$host_leaf_id"); // Retrieve the host specific information from the host table $host_country = db_fetch_cell(" SELECT ebEnhancedInfo_country FROM host...
You're reading from Cacti 0.8 Beginner's Guide
The rest of the page is locked
You have been reading a chapter from
Cacti 0.8 Beginner's GuidePublished in: Mar 2011Publisher: PacktISBN-13: 9781849513920
© 2011 Packt Publishing Limited All Rights Reserved