This is my third post in as many days and I hope I'm not annoying anyone! I was trying to scale an image to fit the screen on my Android device and from the example I was given it seems it is a bit over my head and not as easy as I thought it would be. I have come up with an even better way to achieve my goal and this idea is more preferred as it has an added bonus. The idea, is to display an image inside a Browser Widget and have the added feature of being able to pinch to zoom on the image also. I have tested and got the image to display using the following simple html code.
Code: Select all
<html>
<head>
<style>
* {
margin: 0;
padding: 0;
}
.imgbox {
display: grid;
height: 100%;
}
.center-fit {
max-width: 100%;
max-height: 100vh;
margin: auto;
}
</style>
</head>
<body>
<div class="imgbox">
<img class="center-fit" src='./BIRD.jpg'>
</div>
</body>
</html>
Would it even be possible to point the BIRD.jpg portion of the html file to a "documents" folder? I have tried many different options in the past day and have had no luck. I hope I have been able to explain this clearly.
Any ideas are warmly welcomed!
Googie.