Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added photo viewer. Fixes Add photo viewer #6 #18

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
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
Jump to file
Failed to load files.
Loading
Diff view
Diff view
81 changes: 57 additions & 24 deletions index.html
Original file line number Diff line number Diff line change
@@ -1,17 +1,21 @@
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>30 days of scam</title>


<link rel="stylesheet" href="style.css">
</head>

<body>
<nav class="nav">
<img src="assets/modiji2.jpg" alt="har ghar modi">
<h2>30 days of scam</h2>

</nav>
<main>
<div class="subheading">
Expand All @@ -20,42 +24,70 @@ <h2>Developed by guugle and government of bindia</h2>
<!-- div for memes -->
<div class="images">
<!-- <img src="assets/memes/1.jpeg" alt="" srcset=""> -->
<img src="assets/memes/2.jpeg" alt="" srcset="">
<img src="assets/memes/3.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/2.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/3.jpeg" alt="" srcset="">
<!-- <img src="assets/memes/4.jpeg" alt="" srcset=""> -->
<img src="assets/memes/5.jpeg" alt="" srcset="">
<img src="assets/memes/6.jpeg" alt="" srcset="">
<img src="assets/memes/7.jpeg" alt="" srcset="">
<img src="assets/memes/8.jpeg" alt="" srcset="">
<img src="assets/memes/9.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/6.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/7.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/5.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/8.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/9.jpeg" alt="" srcset="">
<!-- <img src="assets/memes/10.jpeg" alt="" srcset=""> -->
<img src="assets/memes/11.jpeg" alt="" srcset="">
<img src="assets/memes/12.jpeg" alt="" srcset="">
<img src="assets/memes/13.jpeg" alt="" srcset="">
<img src="assets/memes/14.jpeg" alt="" srcset="">
<img src="assets/memes/15.jpeg" alt="" srcset="">
<img src="assets/memes/16.jpeg" alt="" srcset="">
<img src="assets/memes/17.jpeg" alt="" srcset="">
<img src="assets/memes/18.jpeg" alt="" srcset="">
<img src="assets/memes/19.jpeg" alt="" srcset="">
<img src="assets/memes/20.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/11.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/12.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/13.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/14.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/15.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/16.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/17.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/18.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/19.jpeg" alt="" srcset="">
<img onclick="displayModal(this.src)" src="assets/memes/20.jpeg" alt="" srcset="">
</div>\


<!-- The Modal -->
<div id="myModal" class="modal">

<!-- The Close Button -->
<span class="close">&times;</span>

<!-- Modal Content (The Image) -->
<img class="modal-content" id="img01">

<!-- Modal Caption (Image Text) -->
<div id="caption"></div>
</div>


<!-- div for about -->


<div>
<h2>About us</h2>
<h3>If you feel to contribute to the site visit this repository, we are open to all suggestions and content</h3>
<h3>If you feel to contribute to the site visit this repository, we are open to all suggestions and content
</h3>
<h4>https://github.com/apoorvpandey0/30daysofscam-html</h4>
<hr>
<h3>Also consider supporting us by Buying us a coffee at:</h3>
<script type="text/javascript" src="https://cdnjs.buymeacoffee.com/1.0.0/button.prod.min.js" data-name="bmc-button" data-slug="ankurg132" data-color="#FFDD00" data-emoji="" data-font="Cookie" data-text="Buy me a coffee" data-outline-color="#000000" data-font-color="#000000" data-coffee-color="#ffffff" ></script>
<h3>All the fund raised will be donated to guugle for improving their servers. Stay tuned for more info.</h3>
<script type="text/javascript" src="https://cdnjs.buymeacoffee.com/1.0.0/button.prod.min.js"
data-name="bmc-button" data-slug="ankurg132" data-color="#FFDD00" data-emoji="" data-font="Cookie"
data-text="Buy me a coffee" data-outline-color="#000000" data-font-color="#000000"
data-coffee-color="#ffffff"></script>
<h3>All the fund raised will be donated to guugle for improving their servers. Stay tuned for more info.
</h3>
<hr>
<h2>Memes are created by our beloved GDSC community, mostly GDSC JGEC thanks :)</h2>
</div>


</main>
<script id="_wauzu0">var _wau = _wau || []; _wau.push(["dynamic", "1hxmkb02rr", "zu0", "c4302bffffff", "small"]);</script><script async src="//waust.at/d.js"></script>

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

<script
id="_wauzu0">var _wau = _wau || []; _wau.push(["dynamic", "1hxmkb02rr", "zu0", "c4302bffffff", "small"]);</script>
<script async src="//waust.at/d.js"></script>
<footer>
<div>
<img src="assets/logos/1.png" alt="" srcset="">
Expand All @@ -65,8 +97,9 @@ <h2>Memes are created by our beloved GDSC community, mostly GDSC JGEC thanks :)<
<img src="assets/logos/5.png" alt="" srcset="">
<img src="assets/logos/6.png" alt="" srcset="">
<img src="assets/logos/7.png" alt="" srcset="">

</div>
</footer>
</body>
</html>

</html>
21 changes: 21 additions & 0 deletions js/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
// Get the modal
var modal = document.getElementById("myModal");

// Get the image and insert it inside the modal - use its "alt" text as a caption
var img = document.getElementById("myImg");
var modalImg = document.getElementById("img01");
var captionText = document.getElementById("caption");

function displayModal(image) {
modalImg.src = image;
modal.style.display = "block";
captionText.innerHTML = this.alt;
}

// Get the <span> element that closes the modal
var span = document.getElementsByClassName("close")[0];

// When the user clicks on <span> (x), close the modal
span.onclick = function () {
modal.style.display = "none";
}
72 changes: 72 additions & 0 deletions style.css
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,76 @@
.images > img {
width: 30%;
}
}


/* The Modal (background) */
.modal {
display: none; /* Hidden by default */
position: fixed; /* Stay in place */
z-index: 1; /* Sit on top */
padding-top: 100px; /* Location of the box */
left: 0;
top: 0;
width: 100%; /* Full width */
height: 100%; /* Full height */
overflow: auto; /* Enable scroll if needed */
background-color: rgb(0,0,0); /* Fallback color */
background-color: rgba(0,0,0,0.9); /* Black w/ opacity */
}

/* Modal Content (Image) */
.modal-content {
margin: auto;
display: block;
width: 80%;
max-width: 700px;
}

/* Caption of Modal Image (Image Text) - Same Width as the Image */
#caption {
margin: auto;
display: block;
width: 80%;
max-width: 700px;
text-align: center;
color: #ccc;
padding: 10px 0;
height: 150px;
}

/* Add Animation - Zoom in the Modal */
.modal-content, #caption {
animation-name: zoom;
animation-duration: 0.6s;
}

@keyframes zoom {
from {transform:scale(0)}
to {transform:scale(1)}
}

/* The Close Button */
.close {
position: absolute;
top: 15px;
right: 35px;
color: #f1f1f1;
font-size: 40px;
font-weight: bold;
transition: 0.3s;
}

.close:hover,
.close:focus {
color: #bbb;
text-decoration: none;
cursor: pointer;
}

/* 100% Image Width on Smaller Screens */
@media only screen and (max-width: 700px){
.modal-content {
width: 100%;
}
}