</div> </div> <div class="form-group"> <label for="fileimgview" class="col-sm-3 control-label">Veľký náhlad:</label> <div class="col-sm-9"> <input type="text" class="form-control" id="fileimgview" name="fileimgview" value="' . $data["down_imgview"] . '"> </div> </div> <div class="form-group"> <label for="filekat" class="col-sm-3 control-label">Kategória súboru:</label> <div class="col-sm-9">'; $result = dbquery("SELECT * FROM bg_downloadcats"); $rows1 = dbrows($result); if ($rows1 >= "1") { echo '<select name="filekat" class="form-control">'; echo '<option value="' . $data["down_cat"] . '" selected>' . downloadcat($data["down_cat"]) . '</option>'; echo '<option value="">- Výber kategórie -</option>'; while ($data1 = dbarray($result)) { echo '<option value="' . $data1["downc_id"] . '">' . $data1["downc_name"] . '</option>'; } echo '</select>'; } else { echo "Žiadne kategorie k downloadom."; } echo ' </div> </div> <div class="form-group"> <label for="fileimg" class="col-sm-3 control-label">Náhľad (malý):</label> <div class="col-sm-9"> ';
} $limit = "12"; $celkovy_pocet = $rows1; $pocet_stran = ceil($celkovy_pocet / $limit); $pociatok = $strana * $limit - $limit; $result = dbquery("SELECT * FROM bg_downloads " . $cat . " ORDER BY down_id DESC LIMIT {$pociatok}, {$limit}"); if ($strana > $pocet_stran) { redirect("/"); } echo '<div class="row">'; while ($data = dbarray($result)) { echo '<div class="col-sm-6 col-md-3"><div class="subor"> <a href="/subory/subor/' . $data["down_id"] . '/' . bezd($data["down_name"]) . '" data-lightbox="image" title=""><img src="http://data.desart.sk/downloadimg/' . $data["down_img"] . '"/></a> <div class="subortxt"> <div class="stitle"><a href="/subory/subor/' . $data["down_id"] . '/' . bezd($data["down_name"]) . '">' . $data["down_name"] . '</a></div> ' . downloadcat($data["down_cat"]) . ' </div> </div></div>'; } echo '</div>'; pagination($rows1, $limit, $pocet_stran, $strana); } else { echo "<p style='text-align:center;'>Žiadne súbory.</p>"; } if (isset($_GET["suborid"])) { if (!ctype_digit($_GET['suborid'])) { redirect("/"); } $resultsubor = dbquery("SELECT * FROM bg_downloads WHERE down_id='" . $_GET['suborid'] . "' LIMIT 0,1"); $datas = dbarray($resultsubor); $hodnotilox = dbcount("(rate_pageid)", "bg_ratestar", "rate_pageid='" . $datas["down_id"] . "' AND rate_type='S'");