Sridhar_111831
Mar 06, 2014Nimbostratus
Unable to make LocalLB.VirtualServer get_default_pool_name work
All,
New to icontrol and php - pardon my knowledge. Writing a php to get VS , Pool Name and Status of VS. Im able to pull the status of VS and VS Name. However, the pool name would not load and comes up blank. I also see the error - Trying to get property of non-object in /var/www/html/learn/test.php
Any advise?
Code -
$vs_list=$client->get_list();
sort($vs_list);
$vsstatus=$client->get_object_status($vs_list);
$poollist=$client->get_default_pool_name($vs_list);
.............................
foreach ($vs_list as $index=>$vs)
{
$pool_name=$poollist[$index]->pool_name;
$availability_status=$vsstatus[$index]->availability_status;
$img = getgif($availability_status);
echo "";
echo "$vs";
echo "$pool_name";
echo "";
echo "";
}
-Sridhar