Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
72 changes: 72 additions & 0 deletions Week_1/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet">
<link rel="stylesheet" href="style.css">
<title>Class Timetable</title>
</head>
<body>
<div class="container my-5">
<h1 class="text-center">Class Timetable</h1>
<div class="table-responsive">
<table class="table table-bordered text-center">
<thead>
<tr>
<th>Hours</th>
<th>Mon</th>
<th>Tue</th>
<th>Wed</th>
<th>Thurs</th>
<th>Fri</th>
</tr>
</thead>
<tbody>
<tr>
<td>1st Hour</td>
<td onclick="showTeacherDetails('science')">Science</td>
<td onclick="showTeacherDetails('maths')">Maths</td>
<td onclick="showTeacherDetails('science')">Science</td>
<td onclick="showTeacherDetails('maths')">Maths</td>
<td onclick="showTeacherDetails('arts')">Arts</td>
</tr>
<tr>
<td>2nd Hour</td>
<td onclick="showTeacherDetails('social')">Social</td>
<td onclick="showTeacherDetails('hindi')">Hindi</td>
<td onclick="showTeacherDetails('english')">English</td>
<td onclick="showTeacherDetails('social')">Social</td>
<td onclick="showTeacherDetails('sports')">Sports</td>
</tr>
<tr class="lunch-row">
<td colspan="6">Lunch Break</td>
</tr>
<tr>
<td>3rd Hour</td>
<td onclick="showTeacherDetails('science')">Science</td>
<td onclick="showTeacherDetails('maths')">Maths</td>
<td onclick="showTeacherDetails('science')">Science</td>
<td onclick="showTeacherDetails('maths')">Maths</td>
<td onclick="showTeacherDetails('project')">Project</td>
</tr>
<tr>
<td>4th Hour</td>
<td onclick="showTeacherDetails('social')">Social</td>
<td onclick="showTeacherDetails('hindi')">Hindi</td>
<td onclick="showTeacherDetails('english')">English</td>
<td onclick="showTeacherDetails('social')">Social</td>
<td></td>
</tr>
</tbody>
</table>
</div>
</div>

<script>
function showTeacherDetails(subject) {
window.location.href = `teacher.html?subject=${subject}`;
}
</script>
</body>
</html>
54 changes: 54 additions & 0 deletions Week_1/styles.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
body {
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
background-color: #f8f9fa;
color: #333;
}h1 {
margin-bottom: 30px;
font-size: 2.5rem;
color: #007bff;
font-weight: bold;
text-shadow: 1px 1px 3px #b0bec5;
}table {
width: 100%;
background-color: white;
border-radius: 10px;
box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
overflow: hidden;
}th {
background-color: #007bff;
color: white;
text-transform: uppercase;
padding: 15px;
}td {
padding: 20px;
text-align: center;
font-size: 1.1rem;
cursor: pointer;
transition: background-color 0.3s, color 0.3s;
}td:hover {
background-color: #e3f2fd;
color: #007bff;
font-weight: bold;
transform: scale(1.05);
}tr:nth-child(even) {
background-color: #f1f1f1;
}tr:nth-child(odd) {
background-color: #ffffff;
}.lunch-row td {
background-color: #ffeb3b;
font-weight: bold;
color: #333;
}/* Responsive design */
@media (max-width: 768px) {
td, th {
font-size: 0.9rem;
padding: 10px;
}
}@media (max-width: 576px) {
td, th {
font-size: 0.8rem;
padding: 8px;
} h1 {
font-size: 1.8rem;
}
}
64 changes: 64 additions & 0 deletions Week_1/teacher.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet">
<style>
body {
background-color: #f8f9fa;
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
color: #333;
}

h2 {
color: #007bff;
font-weight: bold;
}

#teacher-details {
background-color: white;
padding: 20px;
border-radius: 8px;
box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
}

.btn {
margin-top: 20px;
}
</style>
<title>Teacher Details</title>
</head>
<body>
<div class="container my-5">
<h2 id="subject-name"></h2>
<div id="teacher-details" class="mt-4">
<p id="teacher-name"></p>
<p id="teacher-email"></p>
</div>
<a href="index.html" class="btn btn-primary">Back to Timetable</a>
</div>

<script>
const urlParams = new URLSearchParams(window.location.search);
const subject = urlParams.get('subject');
const teacherData = {
science: { name: 'Mr. Sharma', email: 'sharma@school.com' },
maths: { name: 'Mrs. Gupta', email: 'gupta@school.com' },
hindi: { name: 'Mr. Patel', email: 'patel@school.com' },
english: { name: 'Ms. Khan', email: 'khan@school.com' },
social: { name: 'Mr. Roy', email: 'roy@school.com' },
arts: { name: 'Ms. Singh', email: 'singh@school.com' },
sports: { name: 'Mr. Verma', email: 'verma@school.com' },
project: { name: 'Mr. Kumar', email: 'kumar@school.com' }
};

document.getElementById('subject-name').textContent = subject.toUpperCase() + " Teacher Details";
const teacher = teacherData[subject.toLowerCase()];
if (teacher) {
document.getElementById('teacher-name').textContent = `Name: ${teacher.name}`;
document.getElementById('teacher-email').textContent = `Email: ${teacher.email}`;
}
</script>
</body>
</html>
29 changes: 29 additions & 0 deletions Week_2/Project_1/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Cat Facts</title>
<link rel="stylesheet" href="style.css">
</head>

<body>
<div class="container">
<div class="image-container">
<img src="https://images.unsplash.com/photo-1543201245-c9031909fe6f?w=500&auto=format&fit=crop&q=60&ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxleHBsb3JlLWZlZWR8MTd8fHxlbnwwfHx8fHw%3D" alt="There should be a cat image" class="cat-image">
</div>

<h1 class="title">Let's Learn About Cats</h1>

<div id="catfactdiv" class="fact-box">
<p>This is empty now</p>
</div>

<button id="btn" class="load-btn">Click Me to Load a Cat Fact</button>
</div>

<script src="script.js"></script>
</body>

</html>
18 changes: 18 additions & 0 deletions Week_2/Project_1/script.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
const mybox=document.getElementById('catfactdiv')

const catfacturl="https://catfact.ninja/fact"

const btn=document.getElementById('btn')

async function catfact() {
const responce =await fetch(catfacturl);
const data=await responce.json();
console.log(data);
mybox.innerText=data.fact
}


btn.addEventListener('click',()=>{
console.log("btn clicked");
catfact()
})
93 changes: 93 additions & 0 deletions Week_2/Project_1/style.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
/* Reset some default styling */
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}

/* Style the body */
body {
font-family: 'Arial', sans-serif;
background-color: #f5f5f5;
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
padding: 20px;
}

/* Container for layout */
.container {
text-align: center;
background-color: white;
padding: 20px;
border-radius: 12px;
box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
max-width: 500px;
width: 100%;
}

/* Style the cat image */
.image-container {
margin-bottom: 20px;
}

.cat-image {
width: 100%;
border-radius: 10px;
object-fit: cover;
transition: transform 0.3s ease;
}

.cat-image:hover {
transform: scale(1.05);
}

/* Title styling */
.title {
font-size: 24px;
color: #333;
margin-bottom: 20px;
font-weight: bold;
}

/* Fact box styling */
.fact-box {
font-size: 16px;
color: #555;
background-color: #eef;
padding: 15px;
margin-bottom: 20px;
border-radius: 8px;
}

/* Button styling */
.load-btn {
font-size: 16px;
padding: 10px 20px;
background-color: #28a745;
color: white;
border: none;
border-radius: 8px;
cursor: pointer;
transition: background-color 0.3s ease;
}

.load-btn:hover {
background-color: #218838;
}

/* Responsive adjustments */
@media (max-width: 600px) {
.container {
padding: 15px;
}

.title {
font-size: 20px;
}

.load-btn {
padding: 8px 15px;
}
}
25 changes: 25 additions & 0 deletions Week_2/todo/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<div id="root">
<div id="inputformdiv">
<input type="text" id="name" placeholder="Enter your name">
<input type="text" id="task" placeholder="Enter your task">
</div>
<div id="btn">
<button id="add">Add the Data</button>
<button id="delete">Delete all Data</button>
</div>
</div>



<script src="script.js"></script>
</body>
</html>
Loading