Du kannst nicht mehr als 25 Themen auswählen
Themen müssen mit entweder einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.
123456789101112 |
- function myFunction(imgs) {
- // Get the expanded image
- var expandImg = document.getElementById("expandedImg");
- // Get the image text
- var imgText = document.getElementById("imgtext");
- // Use the same src in the expanded image as the image being clicked on from the grid
- expandImg.src = imgs.src;
- // Use the value of the alt attribute of the clickable image as text inside the expanded image
- imgText.innerHTML = imgs.alt;
- // Show the container element (hidden with CSS)
- expandImg.parentElement.style.display = "block";
- }
|