X7ROOT File Manager
Current Path:
/home/u126090504/domains/svmbaripada.org.in/public_html
home
/
u126090504
/
domains
/
svmbaripada.org.in
/
public_html
/
📄
+2-science-&-+2arts.php
(8.87 KB)
📁
..
📄
.htaccess
(1.12 KB)
📄
Antiraging-Cell.php
(2.73 KB)
📄
about-us.php
(8.85 KB)
📄
academic-calendar.php
(2.73 KB)
📄
achievements.php
(9.56 KB)
📄
achievers.php
(15.19 KB)
📁
admin
📄
admission-process.php
(9.23 KB)
📄
admission.php
(13.96 KB)
📄
admission_submit.php
(3.38 KB)
📄
album.php
(890 B)
📄
assessment-policy.php
(7.08 KB)
📄
class-1-to-5th.php
(7.78 KB)
📄
class6th-to-10th.php
(7.96 KB)
📄
computer-courses.php
(22.83 KB)
📄
config.php
(1.21 KB)
📄
contact-us.php
(14.63 KB)
📄
contactdb.php
(796 B)
📄
courses.php
(10.44 KB)
📁
css
📄
director's-message.php
(6.49 KB)
📄
downloads.php
(2.9 KB)
📄
error.log
(14.6 KB)
📄
facilities.php
(6.57 KB)
📄
faculty.php
(10.27 KB)
📄
fee-structure.php
(7.97 KB)
📁
fonts
📄
footer.php
(17.95 KB)
📄
franchise.php
(2.09 KB)
📄
gallery.php
(3.05 KB)
📄
grievance-form.php
(16.84 KB)
📄
header.php
(20.08 KB)
📄
homework.php
(9.64 KB)
📁
images
📄
index.php
(46.64 KB)
📄
infrastructure-details.php
(5.48 KB)
📁
js
📁
lib
📄
managing-committee.php
(3.34 KB)
📄
media-corner.php
(2.48 KB)
📄
non-academic-achievers.php
(14.65 KB)
📄
payment.php
(23.12 KB)
📄
payment_submit.php
(15.1 KB)
📄
payment_verify.php
(2.31 KB)
📄
peret.php
(266.87 KB)
📄
placement.php
(8.33 KB)
📄
principal's-message.php
(6.33 KB)
📄
public-disclosure.php
(3.38 KB)
📁
qrcodes
📁
revolution
📄
scope.php
(14.14 KB)
📄
search_videos.php
(1.76 KB)
📄
shyam-classes.php
(6.91 KB)
📄
submit-grievance.php
(3.88 KB)
📄
thank-you.php
(1.28 KB)
📁
uploads
📄
videos.php
(6.87 KB)
Editing: homework.php
<?php require_once 'config.php'; include 'header.php'; date_default_timezone_set('Asia/Kolkata'); /* Data for filters */ $classes = $conn->query("SELECT id, name FROM classes ORDER BY id"); $subjects = $conn->query("SELECT id, name, class_id FROM subjects ORDER BY class_id, name"); $sections = $conn->query("SELECT id, name, class_id FROM sections ORDER BY class_id, name"); /* Read filters */ $class_id = isset($_GET['class_id']) ? (int)$_GET['class_id'] : 0; $section_id = (isset($_GET['section_id']) && $_GET['section_id'] !== '') ? (int)$_GET['section_id'] : null; $subject_id = isset($_GET['subject_id']) ? (int)$_GET['subject_id'] : 0; $assign_dt = $_GET['date'] ?? date('Y-m-d'); /* Query */ $sql = "SELECT h.*, c.name AS class_name, s.name AS section_name, sub.name AS subject_name FROM homework h JOIN classes c ON c.id = h.class_id JOIN subjects sub ON sub.id = h.subject_id LEFT JOIN sections s ON s.id = h.section_id WHERE h.status = 'active'"; $types = ""; $vals = []; if ($assign_dt) { $sql .= " AND h.assign_date=?"; $types.="s"; $vals[]=$assign_dt; } if ($class_id) { $sql .= " AND h.class_id=?"; $types.="i"; $vals[]=$class_id; } if (!is_null($section_id) && $section_id>0) { $sql .= " AND h.section_id=?"; $types.="i"; $vals[]=$section_id; } if ($subject_id){ $sql .= " AND h.subject_id=?"; $types.="i"; $vals[]=$subject_id; } $sql .= " ORDER BY sub.name, h.id DESC"; $stmt = $conn->prepare($sql); if ($types) $stmt->bind_param($types, ...$vals); $stmt->execute(); $res = $stmt->get_result(); ?> <style> /* ===== SCOPED STYLES: nothing outside #hw-scope is affected ===== */ #hw-scope { --accent:#e11d2e; --text:#222; --muted:#666; --line:#e9ecef; --card:#fff; --radius:14px; } #hw-scope, #hw-scope * { box-sizing: border-box; } /* keep site fonts as-is; no global font override */ #hw-scope .hw-hero{ background: var(--accent); color:#fff; padding: 40px 0 32px; text-align:center; line-height:1.25; } #hw-scope .hw-hero h1{ margin:0; font-weight:800; font-size: clamp(26px, 3.2vw, 42px); } #hw-scope .hw-hero p{ margin:6px 0 0; font-size:14px; opacity:.95; } /* container that doesn't rely on theme */ #hw-scope .wrap{ width:100%; max-width:1200px; margin:0 auto; padding:0 16px; } /* filter card */ #hw-scope .filter-card{ position: relative; margin-top: -28px; /* sit slightly into hero */ z-index: 2; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 6px 20px rgba(0,0,0,.06); padding: 18px; } #hw-scope .filter-row{ display:flex; flex-wrap:wrap; gap:14px; } #hw-scope .filter-col{ flex:1 1 220px; min-width:220px; } #hw-scope .form-label{ display:block; margin:0 0 6px; color:#444; font-size:13px; font-weight:600; } #hw-scope .control{ width:100%; height:44px; padding:8px 12px; border:1px solid #d0d5dd; border-radius:10px; background:#fff; color:#333; line-height:1.2; } #hw-scope .control:focus{ outline: none; border-color: var(--accent); box-shadow: 0 0 0 .15rem rgba(225,17,30,.15); } #hw-scope .btns{ display:flex; gap:10px; margin-top:4px; } #hw-scope .btn-red{ background:var(--accent); color:#fff; border:none; border-radius:10px; padding:10px 18px; font-weight:700; cursor:pointer; } #hw-scope .btn-outline{ display:inline-block; text-decoration:none; text-align:center; border:1px solid var(--accent); color:var(--accent); background:#fff; border-radius:10px; padding:10px 18px; font-weight:700; } #hw-scope .btn-outline:hover{ color:#fff; background:var(--accent); } /* list/cards */ #hw-scope .list{ display:flex; flex-direction:column; gap:16px; margin: 22px 0 36px; } #hw-scope .card{ background:#fff; border:1px solid var(--line); border-radius: var(--radius); padding:18px 20px; box-shadow: 0 2px 10px rgba(0,0,0,.04); transition: transform .15s ease, box-shadow .15s ease; } #hw-scope .card:hover{ transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0,0,0,.08); } #hw-scope .row-between{ display:flex; justify-content:space-between; align-items:center; gap:12px; flex-wrap:wrap; } #hw-scope .badge-class{ display:inline-block; background:#f1f5f9; color:#444; border-radius:999px; padding:5px 10px; font-size:12px; font-weight:700; margin-right:6px; } #hw-scope .badge-sub{ display:inline-block; background:var(--accent); color:#fff; border-radius:999px; padding:5px 10px; font-size:12px; font-weight:700; } #hw-scope .due{ color:var(--accent); font-weight:700; } #hw-scope .title{ margin:8px 0 4px; color:var(--text); font-weight:800; font-size:18px; line-height:1.35; } #hw-scope .desc{ color:#444; white-space:pre-line; line-height:1.5; } #hw-scope .meta{ color:var(--muted); font-size:13px; } #hw-scope .attach a{ color:var(--accent); font-weight:700; text-decoration:none; } #hw-scope .attach a:hover{ text-decoration:underline; } #hw-scope .empty{ background:#fff; border:1px solid var(--line); border-radius:var(--radius); padding:18px; text-align:center; color:#444; } @media (max-width: 768px){ #hw-scope .filter-card{ padding:14px; } } </style> <div id="hw-scope"> <!-- HERO --> <section class="hw-hero"> <div class="wrap"> <h1 style="color:white;">Today's Homework</h1> <p>Today's Homework (<?= htmlspecialchars(date('d M Y', strtotime($assign_dt))) ?>)</p> </div> </section> <br/><br/> <!-- FILTERS --> <div class="wrap"> <form class="filter-card" method="get"> <div class="filter-row"> <div class="filter-col"> <label class="form-label">Class</label> <select class="control" name="class_id" id="class_id"> <option value="0">All</option> <?php $classes->data_seek(0); while($c=$classes->fetch_assoc()): ?> <option value="<?= $c['id'] ?>" <?= $class_id==$c['id']?'selected':'' ?>><?= htmlspecialchars($c['name']) ?></option> <?php endwhile; ?> </select> </div> <div class="filter-col"> <label class="form-label">Section</label> <select class="control" name="section_id" id="section_id"> <option value="">All</option> <?php $sections->data_seek(0); while($s=$sections->fetch_assoc()): ?> <option data-class="<?= $s['class_id'] ?>" value="<?= $s['id'] ?>" <?= (!is_null($section_id) && $section_id==$s['id'])?'selected':'' ?>> <?= htmlspecialchars($s['name']) ?> </option> <?php endwhile; ?> </select> </div> <div class="filter-col"> <label class="form-label">Subject</label> <select class="control" name="subject_id" id="subject_id"> <option value="0">All</option> <?php $subjects->data_seek(0); while($s=$subjects->fetch_assoc()): ?> <option data-class="<?= $s['class_id'] ?>" value="<?= $s['id'] ?>" <?= $subject_id==$s['id']?'selected':'' ?>> <?= htmlspecialchars($s['name']) ?> </option> <?php endwhile; ?> </select> </div> <div class="filter-col"> <label class="form-label">Date</label> <input type="date" class="control" name="date" value="<?= htmlspecialchars($assign_dt) ?>"> </div> </div> <div class="btns"> <button class="btn-red" type="submit">Filter</button> <a class="btn-outline" href="homework.php">Today</a> </div> </form> </div> <!-- RESULTS --> <div class="wrap"> <?php if($res->num_rows==0): ?> <div class="empty">No homework found for selected filters.</div> <?php endif; ?> <div class="list"> <?php while($r=$res->fetch_assoc()): ?> <div class="card"> <div class="row-between"> <div> <span class="badge-class"><?= htmlspecialchars($r['class_name']) ?><?= $r['section_name']?' - '.htmlspecialchars($r['section_name']):'' ?></span> <span class="badge-sub"><?= htmlspecialchars($r['subject_name']) ?></span> </div> <?php if($r['due_date']): ?> <div class="due">Due: <?= htmlspecialchars(date('d M Y', strtotime($r['due_date']))) ?></div> <?php endif; ?> </div> <h3 class="title"><?= htmlspecialchars($r['title']) ?></h3> <div class="desc"><?= nl2br(htmlspecialchars($r['description'])) ?></div> <div class="row-between" style="margin-top:8px;"> <div class="meta"> Assigned: <?= htmlspecialchars(date('d M Y', strtotime($r['assign_date']))) ?> <?= $r['teacher_name'] ? ' • By: '.htmlspecialchars($r['teacher_name']) : '' ?> </div> <?php if($r['file_path']): ?> <div class="attach"><a href="<?= htmlspecialchars($r['file_path']) ?>" target="_blank" rel="noopener">Attachment</a></div> <?php endif; ?> </div> </div> <?php endwhile; ?> </div> </div> </div> <script> /* Dependent dropdowns (scoped) */ (function(){ const cid = document.getElementById('class_id'); ['section_id','subject_id'].forEach(id=>{ const el = document.getElementById(id); function filter(){ const v = cid.value; [...el.options].forEach(o=>{ if(!o.dataset.class) return; // keep "All" o.hidden = (v !== '0' && o.dataset.class !== v); if(o.selected && o.hidden){ el.value = (el.name === 'section_id' ? '' : '0'); } }); } cid.addEventListener('change', filter); filter(); }); })(); </script> <?php include 'footer.php'; ?>
Upload File
Create Folder