57 lines
2.1 KiB
PHP
57 lines
2.1 KiB
PHP
|
<?php
|
||
|
defined('BASEPATH') OR exit('No direct script access allowed');
|
||
|
|
||
|
$categories = $this->projectsModel->getEntryCategories($ID);
|
||
|
$categoriesClasses = "";
|
||
|
foreach ($categories as $category) {
|
||
|
$categoriesClasses .= $category['collection'] . " ";
|
||
|
}
|
||
|
if ($isDownloadable) {
|
||
|
$categoriesClasses .= 'downloadable ';
|
||
|
}
|
||
|
if ($isOpenSource) {
|
||
|
$categoriesClasses .= 'opensource';
|
||
|
}
|
||
|
?>
|
||
|
<li class="col-4 p-2 <?= $categoriesClasses ?>">
|
||
|
<div class="card">
|
||
|
<a href="<?= base_url('projects/entry/' . $name) ?>">
|
||
|
<div class="card-img-top" style="background-image: url(<?= $source ?>?w=350)">
|
||
|
<h4 class="project-title"><?= $title ?></h4>
|
||
|
|
||
|
<div class="info-icons">
|
||
|
<?php if ($isDownloadable): ?>
|
||
|
<div class="info-icon" data-toggle="tooltip" data-placement="top" title="<?= lang('projects_download') ?>">
|
||
|
<i class="fa fa-cloud-download-alt"></i>
|
||
|
</div>
|
||
|
<?php endif;
|
||
|
if ($isOpenSource): ?>
|
||
|
<div class="info-icon" data-toggle="tooltip" data-placement="bottom" title="<?= lang('projects_opensource') ?>">
|
||
|
<i class="fab fa-osi"></i>
|
||
|
</div>
|
||
|
<?php endif; ?>
|
||
|
</div>
|
||
|
</div>
|
||
|
</a>
|
||
|
<div class="card-body">
|
||
|
<p class="card-text">
|
||
|
<?= $description ?>
|
||
|
</p>
|
||
|
|
||
|
<p class="card-text">
|
||
|
<small class="text-muted">
|
||
|
<i class="far fa-clock"></i>
|
||
|
<?= date('d.m.Y', strtotime($datetime)) ?>
|
||
|
<span class="date text-hide">
|
||
|
<?= strtotime($datetime) ?>
|
||
|
</span>
|
||
|
<br>
|
||
|
<i class="far fa-<?= $voteCount >= 0 ? 'thumbs-up' : 'thumbs-down' ?>"></i>
|
||
|
<span class="voteCount">
|
||
|
<?= $voteCount ?>
|
||
|
</span>
|
||
|
</small>
|
||
|
</p>
|
||
|
</div>
|
||
|
</div>
|
||
|
</li>
|