Ich habe eine Webseite mit einer Registerkarte namens "Fotos". Es läuft vor Ort. Bei der Auswahl der Registerkarte lädt das Foto "paris.jpg", das 800px x 450px beträgt. Egal was ich versuche, das Foto wird in eine kleine Schachtel mit gebundenen Schriftrollenstangen gelegt. Ich möchte, dass der Rahmen eingestellt wird, um das gesamte Foto ohne Schriftrollenstangen zu halten. < /P>
body {
font-size: 25px;
font-family: Arial ;
}
.tab {
overflow: visible;
}
/* Style the buttons inside the tab */
.tab button {
background-color: inherit;
float: right;
border: none;
outline: none;
cursor: pointer;
padding: 7px 40px;
}
.tabcontent {
display: none;
position: relative;
}
Photos
function openActivity(evt, activityName) {
var i, tabcontent, tablinks;
tabcontent = document.getElementsByClassName("tabcontent");
for (i = 0; i < tabcontent.length; i++) {
tabcontent.style.display = "auto";
tabcontent.style.overflow = "visible";
tabcontent.innerHTML='';
tabcontent.style.width = '100%';
tabcontent.style.height = '100%';
}
tablinks = document.getElementsByClassName("tablinks");
for (i = 0; i < tablinks.length; i++) {
tablinks.className = tablinks.className.replace(" active", "");
}
document.getElementById(activityName).style.display = "block";
evt.currentTarget.className += " active";
}
< /code>
Ich habe versucht, die Anzeige im CSS und die Einstellhöhe und Breite auf 100%anzupassen. Nichts scheint zu funktionieren
Dimensionierung von JPG -Inhalten auf InSEHTML ⇐ JavaScript
-
- Similar Topics
- Replies
- Views
- Last post