Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Setting a maximum height for a source image

Featured Replies

I am trying to create my own very simple image viewer using html/css. I can get everything to work other than 1 aspect.......i am using % widths, not pixels, as I do a lot of panoramas, and would like people with larger windows to be able to see them bigger.....i can get the image to do exactly this, however when i use a standard 3:2 image in the viewer, it results in being way to big for the viewer. I have tried setting a maximum height, which works, but ends up distorting the image as the 100% width still applies. So does anyone know a way to have the width at 100% UNTIL the height reaches 500px, at which point width becomes fixed at the appropriate proportions of the image?! I hope this make sense!

Thanks

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.