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 image in iframe

Featured Replies

Hi,

 

I have a problem regarding 'background-image' inside an iframe. What I would like to do is, that the background image shall remain "stationary" (read: it should remain where it is when the visitor scrolls down the iframe). Is there any way to achieve this, and if so, how? For an example see this page. I have another background image that matches the one outside the iframe, like here, and I would like this second image not to scroll with the content inside the iframe.

 

TIA,

 

Claus

  • 2 weeks later...

I'm not sure I understand your question, but if it's what I think can you not just remove the background colour for the div inhalt_02 and let the background image below show through?

 

Hope that helps!

 

Jennie

I'm not sure I understand your question, but if it's what I think can you not just remove the background colour for the div inhalt_02 and let the background image below show through?

 

Hope that helps!

 

Jennie

 

Or remove the background-image and background-color in the div inhalt_02 in the main page and remove the background-color in daten.html (the page in the iframe) and put a background-image for the body in daten.html with background-attachment: fixed and make the background image fit the background in the main page.

 

background-image: url(image.jpg); background-attachment: fixed; }

Don't know if I'm missing something here, but why are you using an iframe? Why not just use SSI (sever side includes) instead?

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.