Skip to content
  • Recent
  • Tags
  • Popular
  • Users
  • Search
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse

Lay Theme Forum

  1. Home
  2. General Discussion
  3. iframe full size & responsive

iframe full size & responsive

Scheduled Pinned Locked Moved General Discussion
7 Posts 2 Posters 305 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • V Offline
    V Offline
    vernandel
    wrote on last edited by vernandel
    #1

    hi there,
    i want to create a landingpage with an iframe.
    it should be full size & responsive.
    it is working at a regular html site:
    http://klubberlin.de/COOKIESWORLD.html

    when i use the same coding in laytheme the i frame is too big. you can see it that the logo (left top "COOKIESWORLD") and after click the play button the menu at bottom is missing:
    https://360style.de/test_wrapper-copy/

    this is the code i used:

    .video-wrapper {
    position: relative;
    padding-bottom: 100%;
    padding-top: 0;
    overflow: hidden;
    }

    .video-wrapper iframe,
    .video-wrapper object,
    .video-wrapper embed {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    }

    <div class="video-wrapper">
    <iframe width="100%" height="100%" src="https://my.mpskin.com/de/tour/2znh24ebh" frameborder="0" allowfullscreen></iframe>
    </div>

    could you please help me with this
    thank you
    g.

    Bildschirmfoto 2023-04-29 um 08.44.57.png Bildschirmfoto 2023-04-29 um 08.45.09.png

    1 Reply Last reply
    0
    • arminunruhA Offline
      arminunruhA Offline
      arminunruh
      Global Moderator
      wrote on last edited by
      #2

      i see!

      try this css instead:

      .video-container2 {
          position: relative;
          padding-bottom: 100vh;
          overflow: hidden;
      }
      .video-container2 iframe,
      .video-container2 object,
      .video-container2 embed {
          position: absolute;
          top: 0;
          left: 0;
          width: 100%;
          height: 100vh;
      }
      
      V 1 Reply Last reply
      0
      • arminunruhA arminunruh

        i see!

        try this css instead:

        .video-container2 {
            position: relative;
            padding-bottom: 100vh;
            overflow: hidden;
        }
        .video-container2 iframe,
        .video-container2 object,
        .video-container2 embed {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100vh;
        }
        
        V Offline
        V Offline
        vernandel
        wrote on last edited by
        #3

        @arminunruh
        THANK YOU! GREAT:
        https://360style.de/video-wrapper/

        jut 1 more thing:
        how to get ridd of the scrollbar on the right? there is nothing to scroll...

        all the best
        g

        1 Reply Last reply
        0
        • arminunruhA Offline
          arminunruhA Offline
          arminunruh
          Global Moderator
          wrote on last edited by
          #4

          html {
          overflow-y: auto;
          }

          V 1 Reply Last reply
          0
          • arminunruhA arminunruh

            html {
            overflow-y: auto;
            }

            V Offline
            V Offline
            vernandel
            wrote on last edited by vernandel
            #5

            @arminunruh
            hi armin, thank so so far.
            i still have the same problem with the mobile version. (https://360style.de/cookiesworld/) part of the logo is cut off, do you know why?

            also in the mobile version same url:
            https://360style.de/cookiesworld/

            if click on the iframe button it opens a new window. i would like to have it in the same window. i cant find a documentary with iframes.

            thank you so much
            götz

            mobile.jpeg

            V 1 Reply Last reply
            0
            • V vernandel

              @arminunruh
              hi armin, thank so so far.
              i still have the same problem with the mobile version. (https://360style.de/cookiesworld/) part of the logo is cut off, do you know why?

              also in the mobile version same url:
              https://360style.de/cookiesworld/

              if click on the iframe button it opens a new window. i would like to have it in the same window. i cant find a documentary with iframes.

              thank you so much
              götz

              mobile.jpeg

              V Offline
              V Offline
              vernandel
              wrote on last edited by
              #6

              @arminunruh

              hey, did you see my last post/question?
              thank you
              g.

              1 Reply Last reply
              0
              • arminunruhA Offline
                arminunruhA Offline
                arminunruh
                Global Moderator
                wrote on last edited by
                #7

                use this css instead:

                .video-wrapper {
                position: relative;
                padding-bottom: 100svh;
                overflow: hidden;
                }

                .video-wrapper iframe, .video-wrapper object, .video-wrapper embed {
                position: absolute;
                top: 0;
                left: 0;
                width: 100%;
                height: 100svh;
                }

                the difference is we dont use vh, but we use svh

                so anywhere you used 100vh, just use 100svh
                i see i posted some css for you to use here, but i think you may have also used some of your own css, so the gist of it is change your css to use 100svh instead of 100vh anywhere you see 100vh

                if click on the iframe button it opens a new window. i would like to have it in the same window. i cant find a documentary with iframes.

                i think this should work in the same window. this might be an issue with the website you are embedding with the iframe

                1 Reply Last reply
                1
                Reply
                • Reply as topic
                Log in to reply
                • Oldest to Newest
                • Newest to Oldest
                • Most Votes


                I also code custom websites or custom Lay features.
                💿 Email me here: 💿
                info@laytheme.com

                Before you post:
                1. When using a WordPress Cache plugin, disable it or clear your cache.
                2. Update Lay Theme and all Lay Theme Addons
                3. Disable all Plugins
                4. Go to Lay Options → Custom CSS & HTML, click "Turn Off All Custom Code", click "Save Changes"

                This often solves issues you might run into

                When you post:
                1. Post a link to where the problem is
                2. Does the problem happen on Chrome, Firefox, Safari or iPhone or Android?
                3. If the problem is difficult to explain, post screenshots / link to a video to explain it
                Online Users
                Forgot your key, lost your files, need a previous Lay Theme or Addon version? Go to www.laykeymanager.com
                laytheme.com
                • Login

                • Don't have an account? Register

                • Login or register to search.
                • First post
                  Last post
                0
                • Recent
                • Tags
                • Popular
                • Users
                • Search