$fluidbooks = array_values(array_unique($fluidbooks));
$n = 0;
-
foreach ($fluidbooks as $fluidbook) {
if ($n > 5) {
break;
$meta = $ws->getMetadata($fluidbook);
$dir = PUBLIC_PATH . '/references/' . $fluidbook . '-' . CubeIT_Text::str2URL(trim($meta->title));
-
+ try {
+ $res = $ws->installBookIfNeeded($fluidbook, $dir, $meta->date);
+ if ($res) {
+ $n++;
+ }
+ } catch (exception $e) {
+ echo $e->getMessage() . '<br />';
+ }
} catch (exception $e) {
-
+ echo $e->getMessage() . '<br />';
}
-
}
}
}