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.

Background auto resize

Featured Replies

Hey,

 

I'm having problems getting my background to auto resize itself when the window is shrunk or stretched. I want my background to fill the screen and retain its orignal ratio when adjusted by window size. A website which already has this is http://ntslive.co.uk/. I have already tried to get the same results but my background does not stay in proportion with the correct ratios like the NTS site. Here's my site at the moment www.rowancorr.com. Does anyone know the code i need to add to get do this...?

 

Any help would be very much appreciated

 

James.

Try the tips listed either here or here. The first uses predominantly jQuery, while the second is mostly CSS3.

 

Edit: Lol... I didn't see mrchristoph's reply before I posted mine... :p

Edited by ZaLiTH

Hey,

 

I'm having problems getting my background to auto resize itself when the window is shrunk or stretched. I want my background to fill the screen and retain its orignal ratio when adjusted by window size. A website which already has this is http://ntslive.co.uk/. I have already tried to get the same results but my background does not stay in proportion with the correct ratios like the NTS site. Here's my site at the moment www.rowancorr.com. Does anyone know the code i need to add to get do this...?

 

Any help would be very much appreciated

 

James.

Hi James,

I have gone through your website and seen that the width is fine but the problem arises with the height while resizing the window.

So to overcome the problem you simply need to give height as 100% thats all.

Edited by zed
remove crap from post

Hi James,

I have gone through your website and seen that the width is fine but the problem arises with the height while resizing the window.

So to overcome the problem you simply need to give height as 100% thats all.

When set to 'width: 100%; height: 100%;' it does not maintain the aspect ratio, which is not what James wanted. Two working solutions for this have already been posted, we're just waiting for a response now.

 

Also, you might want to refrain from directing people away from WDF for support. The whole point of this forum is for users to help each other and share their experiences, this way everybody has a chance to contribute and learn.

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.