Display correctly the error message when nothing is retrieved from OCS servers

This commit is contained in:
Brice Maron 2011-11-06 16:48:26 +01:00
parent cc35cb74e1
commit 3940ca3df1
2 changed files with 6 additions and 1 deletions

View file

@ -108,6 +108,7 @@ class OC_OCSClient{
$xml=@file_get_contents($url);
if($xml==FALSE){
OC_Log::write('core','Unable to parse OCS content',OC_Log::FATAL);
return NULL;
}
$data=simplexml_load_string($xml);
@ -143,6 +144,7 @@ class OC_OCSClient{
$kbe=array();
$xml=@file_get_contents($url);
if($xml==FALSE){
OC_Log::write('core','Unable to parse knowledgebase content',OC_Log::FATAL);
return NULL;
}
$data=simplexml_load_string($xml);

View file

@ -9,7 +9,10 @@
<?php
$url=OC_Helper::linkTo( "settings", "help.php" ).'?page=';
$pageNavi=OC_Util::getPageNavi($_['pagecount'],$_['page'],$url);
$pageNavi->printPage();
if($pageNavi)
{
$pageNavi->printPage();
}
?>
</diV>
<?php if(is_null($_["kbe"])):?>