Fix HTML catalog when more than 2 prefered format are available
This commit is contained in:
parent
7b382b2420
commit
f5b8918ee0
|
@ -159,9 +159,12 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="download">
|
<div class="download">
|
||||||
<?php
|
<?php
|
||||||
|
$i = 0;
|
||||||
foreach ($config['cops_prefered_format'] as $format)
|
foreach ($config['cops_prefered_format'] as $format)
|
||||||
{
|
{
|
||||||
|
if ($i == 2) { break; }
|
||||||
if ($data = $entry->book->getDataFormat ($format)) {
|
if ($data = $entry->book->getDataFormat ($format)) {
|
||||||
|
$i++;
|
||||||
?>
|
?>
|
||||||
<div class="button buttonEffect"><a href="<?php echo $data->getHtmlLink () ?>"><?php echo $format ?></a></div>
|
<div class="button buttonEffect"><a href="<?php echo $data->getHtmlLink () ?>"><?php echo $format ?></a></div>
|
||||||
<?php
|
<?php
|
||||||
|
|
Loading…
Reference in a new issue