X7ROOT File Manager
Current Path:
/home/u126090504/domains/saiadarshainternationalschool.org.in/public_html
home
/
u126090504
/
domains
/
saiadarshainternationalschool.org.in
/
public_html
/
π
..
π
.htaccess
(0 B)
π
Antiraging-Cell.php
(2.73 KB)
π
SVM-INT (1) (1).zip
(117.51 MB)
π
about-us.php
(5.86 KB)
π
academic-calendar.php
(2.73 KB)
π
achievements.php
(9.56 KB)
π
achievers.php
(15.19 KB)
π
admin
π
admission-process.php
(6.85 KB)
π
admission.php
(12.93 KB)
π
admission_submit.php
(3.38 KB)
π
album.php
(890 B)
π
assessment-policy.php
(6.8 KB)
π
cbse-curriculum-summary.php
(5.99 KB)
π
computer-courses.php
(22.83 KB)
π
config.php
(1.27 KB)
π
contact-us.php
(14.63 KB)
π
contactdb.php
(796 B)
π
courses.php
(10.44 KB)
π
css
π
director's-message.php
(6.54 KB)
π
downloads.php
(2.9 KB)
π
error.log
(14.6 KB)
π
facilities.php
(6.04 KB)
π
faculty.php
(10.27 KB)
π
fee-structure.php
(7.97 KB)
π
fonts
π
footer.php
(23.95 KB)
π
franchise.php
(2.09 KB)
π
gallery.php
(3.05 KB)
π
google929b505e9f42f894.html
(53 B)
π
grievance-form.php
(16.52 KB)
π
header.php
(19.69 KB)
π
homework.php
(9.64 KB)
π
images
π
index.php
(39.38 KB)
π
infrastructure-details.php
(5.39 KB)
π
js
π
lib
π
managing-committee.php
(3.34 KB)
π
media-corner.php
(2.48 KB)
π
non-academic-achievers.php
(14.65 KB)
π
payment.php
(21.85 KB)
π
payment_submit.php
(15.1 KB)
π
payment_verify.php
(2.31 KB)
π
placement.php
(8.33 KB)
π
principal's-message.php
(6.65 KB)
π
public-disclosure.php
(3.38 KB)
π
qrcodes
π
revolution
π
sai
π
scope.php
(14.14 KB)
π
search_videos.php
(1.76 KB)
π
sitemap.xml
(4.69 KB)
π
subjects-offered.php
(6 KB)
π
submit-grievance.php
(3.88 KB)
π
svm
π
thank-you.php
(1.28 KB)
π
u126090504_svmint.sql
(40.87 KB)
π
uploads
π
videos.php
(6.87 KB)
Editing: achievers.php
<?php require_once 'config.php'; include 'header.php'; /* ---------------- Helpers ---------------- */ function column_exists(mysqli $conn, $table, $col){ $q = $conn->query("SHOW COLUMNS FROM `$table` LIKE '".$conn->real_escape_string($col)."'"); return ($q && $q->num_rows > 0); } $hasStatus = column_exists($conn, 'fboard', 'status'); $hasMarksPct = column_exists($conn, 'fboard', 'marks_pct'); /* ---------- Filters & Pagination ---------- */ $perPage = 9; $page = max(1, (int)($_GET['page'] ?? 1)); $offset = ($page - 1) * $perPage; $session = trim($_GET['session'] ?? ''); $course = trim($_GET['course'] ?? ''); $minMarks = $hasMarksPct ? trim($_GET['min_marks'] ?? '') : ''; $q = trim($_GET['q'] ?? ''); // SEARCH LAST $where = []; $params = []; $types = ''; if ($hasStatus) { $where[] = "status='active'"; } if ($session !== '') { $where[] = "exp = ?"; $params[] = $session; $types .= 's'; } if ($course !== '') { $where[] = "des = ?"; $params[] = $course; $types .= 's'; } if ($hasMarksPct && $minMarks !== '' && preg_match('/^\d{1,3}(\.\d{1,2})?$/', $minMarks)) { $where[] = "marks_pct >= ?"; $params[] = (float)$minMarks; $types .= 'd'; } if ($q !== '') { $where[] = "(fname LIKE ? OR des LIKE ? OR exp LIKE ? OR qual LIKE ?)"; $s = "%{$q}%"; array_push($params, $s, $s, $s, $s); $types .= 'ssss'; } $whereSql = $where ? ('WHERE ' . implode(' AND ', $where)) : ''; /* Distinct filter options */ $sessions = []; $courses = []; if ($rs1 = $conn->query("SELECT DISTINCT exp AS session_year FROM fboard ORDER BY exp DESC")) { while ($r = $rs1->fetch_assoc()) $sessions[] = $r['session_year']; } if ($rs2 = $conn->query("SELECT DISTINCT des AS course FROM fboard ORDER BY des ASC")) { while ($r = $rs2->fetch_assoc()) $courses[] = $r['course']; } /* Total count */ $sqlCount = "SELECT COUNT(*) c FROM fboard $whereSql"; $stc = $conn->prepare($sqlCount); if ($types) $stc->bind_param($types, ...$params); $stc->execute(); $total = (int)($stc->get_result()->fetch_assoc()['c'] ?? 0); $pages = max(1, (int)ceil($total / $perPage)); /* Data */ $sql = "SELECT id, fimg, fname, des, exp, qual" . ($hasMarksPct ? ", marks_pct" : "") . " FROM fboard $whereSql ORDER BY id DESC LIMIT ? OFFSET ?"; $stm = $conn->prepare($sql); if ($types) { $bindTypes = $types . 'ii'; $bindParams = array_merge($params, [$perPage, $offset]); $stm->bind_param($bindTypes, ...$bindParams); } else { $stm->bind_param('ii', $perPage, $offset); } $stm->execute(); $res = $stm->get_result(); /* helper for querystring */ function keepQS($extra = []) { $base = $_GET ?: []; foreach ($extra as $k=>$v) $base[$k] = $v; foreach ($base as $k=>$v) if ($v==='') unset($base[$k]); return htmlspecialchars('?' . http_build_query($base)); } ?> <style> /* ---------------- Scoped UI: Academic Achievers ---------------- */ .acachievers-wrapper { --accent:#ea0000; --ink:#111; --bg:#f7f7f9; } .acachievers-wrapper { background: radial-gradient(1200px 600px at 10% -10%, #fff, var(--bg) 70%); isolation: isolate; padding-bottom: 40px; } .acachievers-wrapper .hero { padding: 48px 0 24px; } .acachievers-wrapper .hero .title { font-weight: 800; letter-spacing: .3px; color: var(--ink); display:flex; align-items:center; gap:14px; } .acachievers-wrapper .title .chip { background: linear-gradient(135deg, #ff3d3d, var(--accent)); color:#fff; font-weight:700; padding:6px 12px; border-radius:999px; box-shadow: 0 8px 24px rgba(234,0,0,.22); } /* Filterbar */ .acachievers-wrapper .filterbar { backdrop-filter: blur(10px); background: linear-gradient(180deg, #fff, #fffefc); border: 1px solid #eaeaea; border-radius: 16px; padding: 12px; box-shadow: 0 8px 28px rgba(0,0,0,.06); } .acachievers-wrapper .filterbar .form-control, .acachievers-wrapper .filterbar .custom-select, .acachievers-wrapper .filterbar select { border-radius: 10px !important; } /* Grid + Card */ .acachievers-wrapper .grid { display: grid; gap: 22px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); margin-top: 18px; } .acachievers-wrapper .cardx { position: relative; overflow: hidden; border-radius: 18px; background: linear-gradient(180deg, #ffffff, #fafafa); border: 1px solid #ececec; box-shadow: 0 10px 30px rgba(0,0,0,.08); transition: transform .25s ease, box-shadow .25s ease; } .acachievers-wrapper .cardx:hover { transform: translateY(-6px); box-shadow: 0 18px 44px rgba(0,0,0,.12); } /* IMAGE FULL SHOW (no cropping left/right/top/bottom) */ .acachievers-wrapper .thumbbox { position: relative; background: #fff; width: 100%; aspect-ratio: 1 / 1; /* square: all cards equal height */ display: flex; align-items: center; justify-content: center; overflow: hidden; border-bottom: 1px solid #eee; } .acachievers-wrapper .thumbbox img { width: auto; /* maintain aspect ratio */ height: 100%; /* fit height */ max-width: 100%; /* but never overflow width */ object-fit: contain; /* show full image */ object-position: center center; transition: transform .3s ease; } .acachievers-wrapper .cardx:hover .thumbbox img { transform: scale(1.05); } /* badges */ .acachievers-wrapper .badge-tag { position: absolute; top: 10px; left: 10px; background: #000000cc; color:#fff; font-size:12px; padding:6px 10px; border-radius: 999px; backdrop-filter: blur(6px); z-index:2; } .acachievers-wrapper .marks-badge { position: absolute; top: 10px; right: 10px; background: #ea0000; color:#fff; font-size:12px; padding:6px 10px; border-radius: 999px; font-weight:800; box-shadow: 0 8px 18px rgba(234,0,0,.25); z-index:2; } .acachievers-wrapper .content { padding: 14px 14px 16px; } .acachievers-wrapper .name { font-size: 18px; font-weight: 700; color: var(--ink); margin: 6px 0 2px; } .acachievers-wrapper .meta { display:flex; gap:10px; flex-wrap:wrap; font-size: 13px; color:#555; } .acachievers-wrapper .pill { background:#00000008; border:1px solid #00000010; border-radius:999px; padding:4px 10px; font-weight:600; } .acachievers-wrapper .ach { margin-top:8px; font-weight:700; color:#c40000; } .acachievers-wrapper .viewbtn { margin-top:10px; display:inline-block; border:1px solid var(--accent); color:#fff; background: var(--accent); padding:8px 12px; border-radius: 10px; font-weight:700; text-decoration:none; transition: filter .2s ease; letter-spacing:.2px; } .acachievers-wrapper .viewbtn:hover { filter: brightness(1.1); } /* pagination */ .acachievers-wrapper .pager { display:flex; gap:8px; justify-content:center; align-items:center; margin-top:22px; } .acachievers-wrapper .pager a, .acachievers-wrapper .pager span { min-width:40px; text-align:center; padding:8px 12px; border-radius:10px; border:1px solid #eee; background:#fff; color:#333; text-decoration:none; font-weight:600; } .acachievers-wrapper .pager .active { border-color: var(--accent); color: var(--accent); } /* modal */ .acachievers-wrapper .modal-body .qv-img { width:100%; aspect-ratio: 1/1; object-fit: contain; background:#fff; border-radius: 12px; } </style> <!-- Title/Breadcrumb --> <div class="ttm-page-title-row"> <div class="ttm-page-title-row-inner ttm-textcolor-white"> <div class="container"> <div class="row align-items-center"> <div class="col-lg-12"> <div class="page-title-heading"> <h2 class="title">Academic Achievers</h2> </div> </div> </div> </div> </div> </div> <div class="site-main acachievers-wrapper"> <section class="ttm-row clearfix"> <div class="container"> <!-- Filter Bar (Search LAST) --> <form class="filterbar mb-3" method="get" action=""> <div class="form-row"> <div class="col-md-3 mb-2"> <label class="mb-1"><strong>Session</strong></label> <select name="session" class="custom-select"> <option value="">All Sessions</option> <?php foreach ($sessions as $s): ?> <option value="<?= htmlspecialchars($s) ?>" <?= $session===$s?'selected':'' ?>><?= htmlspecialchars($s) ?></option> <?php endforeach; ?> </select> </div> <div class="col-md-3 mb-2"> <label class="mb-1"><strong>Course</strong></label> <select name="course" class="custom-select"> <option value="">All Courses</option> <?php foreach ($courses as $c): ?> <option value="<?= htmlspecialchars($c) ?>" <?= $course===$c?'selected':'' ?>><?= htmlspecialchars($c) ?></option> <?php endforeach; ?> </select> </div> <?php if ($hasMarksPct): ?> <div class="col-md-2 mb-2"> <label class="mb-1"><strong>Min Marks %</strong></label> <input type="number" step="0.01" min="0" max="100" name="min_marks" class="form-control" value="<?= htmlspecialchars($minMarks) ?>" placeholder="e.g., 80"> </div> <?php endif; ?> <!-- SEARCH LAST --> <div class="col-md-4 mb-2"> <label class="mb-1"><strong>Search</strong></label> <div class="input-group"> <input type="text" name="q" class="form-control" placeholder="Name, course, session, placed atβ¦" value="<?= htmlspecialchars($q) ?>"> <div class="input-group-append"> <button class="btn btn-dark" type="submit">Filter</button> </div> </div> </div> </div> <?php if ($session || $course || $q || ($hasMarksPct && $minMarks !== '')): ?> <div class="mt-2"> <a class="btn btn-link p-0" href="<?= htmlspecialchars(strtok($_SERVER['REQUEST_URI'],'?')) ?>">Clear filters</a> </div> <?php endif; ?> </form> <!-- Results --> <div class="d-flex justify-content-between align-items-center mb-2"> <div><strong><?= $total ?></strong> achiever<?= $total==1?'':'s' ?> found</div> <div class="small text-muted">Page <?= $page ?> of <?= $pages ?></div> </div> <!-- Cards --> <div class="grid"> <?php if ($res && $res->num_rows > 0): while ($row = $res->fetch_assoc()): $fimg = htmlspecialchars($row['fimg'] ?? ''); $name = htmlspecialchars($row['fname']); $des = htmlspecialchars($row['des']); $sess = htmlspecialchars($row['exp']); $qual = htmlspecialchars($row['qual']); $marksDisp = ($hasMarksPct && $row['marks_pct'] !== null) ? number_format((float)$row['marks_pct'], 2) . '%' : ''; $img = $fimg ? "uploads/faculty/{$fimg}" : "assets/img/no-image.png"; ?> <article class="cardx"> <div class="thumbbox"> <img src="<?= $img ?>" alt="<?= $name ?> - <?= $des ?>" onerror="this.src='assets/img/no-image.png'"> <span class="badge-tag"><?= $sess ?></span> <?php if ($marksDisp): ?><span class="marks-badge"><?= $marksDisp ?></span><?php endif; ?> </div> <div class="content"> <div class="name"><?= $name ?></div> <div class="meta"><span class="pill"><i class="fa fa-graduation-cap"></i> <?= $des ?></span></div> <div class="ach"><i class="fa fa-trophy"></i> Placed at: <?= $qual ?></div> </div> </article> <?php endwhile; else: ?> <div class="col-12"><p>No Achievers Found</p></div> <?php endif; ?> </div> <!-- Pagination --> <?php if ($pages > 1): ?> <nav class="pager"> <?php $prev=max(1,$page-1); $next=min($pages,$page+1); ?> <a href="<?= keepQS(['page'=>1]) ?>">«</a> <a href="<?= keepQS(['page'=>$prev]) ?>">‹</a> <?php for($i=max(1,$page-2);$i<=min($pages,$page+2);$i++): ?> <?= $i==$page ? "<span class='active'>$i</span>" : "<a href='".keepQS(['page'=>$i])."'>$i</a>" ?> <?php endfor; ?> <a href="<?= keepQS(['page'=>$next]) ?>">›</a> <a href="<?= keepQS(['page'=>$pages]) ?>">»</a> </nav> <?php endif; ?> </div> </section> </div> <!-- Quick View Modal --> <div class="modal fade" id="qvModal" tabindex="-1" aria-hidden="true"> <div class="modal-dialog modal-lg modal-dialog-centered"> <div class="modal-content"> <div class="modal-body p-0"> <div class="row no-gutters"> <div class="col-md-6"> <img class="qv-img" src="" alt="" id="qvImg"> </div> <div class="col-md-6 p-3"> <h4 id="qvName" class="mb-1"></h4> <div class="text-muted mb-2"><span id="qvSess"></span></div> <div class="mb-2"><strong>Course:</strong> <span id="qvCourse"></span></div> <div class="mb-2"><strong>Placed at:</strong> <span id="qvQual"></span></div> <div class="mb-2" id="qvMarksWrap" style="display:none;"><strong>Secured Marks:</strong> <span id="qvMarks"></span></div> <button type="button" class="btn btn-dark mt-2" data-bs-dismiss="modal">Close</button> </div> </div> </div> </div> </div> </div> <script> // Bootstrap 5 first, fallback to Bootstrap 4 if present document.addEventListener('DOMContentLoaded', function () { document.body.addEventListener('click', function (e) { var btn = e.target.closest('.viewbtn'); if (!btn) return; var name = btn.getAttribute('data-name') || ''; var img = btn.getAttribute('data-img') || ''; var course = btn.getAttribute('data-course') || ''; var sess = btn.getAttribute('data-sess') || ''; var qual = btn.getAttribute('data-qual') || 'β'; var marks = btn.getAttribute('data-marks') || ''; document.getElementById('qvName').textContent = name; document.getElementById('qvCourse').textContent = course; document.getElementById('qvSess').textContent = sess; document.getElementById('qvQual').textContent = qual; var marksWrap = document.getElementById('qvMarksWrap'); if (marks) { document.getElementById('qvMarks').textContent = marks; marksWrap.style.display = ''; } else { marksWrap.style.display = 'none'; } var qvImg = document.getElementById('qvImg'); qvImg.src = img; qvImg.alt = name + ' - ' + course; var modalEl = document.getElementById('qvModal'); if (window.bootstrap && typeof bootstrap.Modal !== 'undefined') { var modal = bootstrap.Modal.getOrCreateInstance(modalEl); modal.show(); } else if (window.jQuery && typeof jQuery.fn.modal === 'function') { jQuery(modalEl).modal('show'); } else { // ultra-basic fallback modalEl.classList.add('show'); modalEl.style.display = 'block'; modalEl.removeAttribute('aria-hidden'); modalEl.addEventListener('click', function(ev){ if (ev.target === modalEl) { modalEl.classList.remove('show'); modalEl.style.display = 'none'; modalEl.setAttribute('aria-hidden','true'); } }, { once:true }); } }, false); }); </script> <?php include 'footer.php'; ?>
Upload File
Create Folder