Results 1 to 8 of 8

Thread: iframe and scrolling

  1. #1
    Join Date
    Mar 2007
    Posts
    43
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default iframe and scrolling

    I have an Iframe that is positioned under a div.

    background-color: #000;
    position: absolute;
    top: 416px;
    left: 5%;
    width: 760px;
    height: auto;
    padding-left: 6px;
    scrolling: no;

    I have the iframe using a different page as its src and because of that the height is not the height of the other page but the height as if there was nothing in the frame. What do I do?

  2. #2
    Join Date
    Jan 2007
    Location
    Bournemouth, England
    Posts
    99
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    1st : Don't use I frames, PHP includes are much better.

    2nd: can you post the Iframe's code.

  3. #3
    Join Date
    Mar 2007
    Posts
    43
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Sure, I hate iframes but I don't know how to insert another page into the code. The iframe code is:

    <iframe id="content" src="http://www.killconrad.com/blog/" marginwidth="0" marginheight="0" hspace="0" vspace="0" frameborder="0" scrolling="no">
    </iframe>

  4. #4
    Join Date
    Jan 2007
    Location
    Bournemouth, England
    Posts
    99
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    <iframe id="content" src="http://www.killconrad.com/blog/" marginwidth="0" marginheight="0" hspace="0" vspace="0" frameborder="0" scrolling="no">
    </iframe>

    and

    position: absolute;
    top: 416px;
    left: 5&#37;;
    width: 760px;
    height: auto;
    padding-left: 6px;
    scrolling: no;

    that might work.

  5. #5
    Join Date
    Mar 2007
    Posts
    43
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    That is what I have for the coding as of right now. But since the src is a different file, it doesn't make it the right height.

    Is there another way to put a separate page as content without iframes. I don't think it's going to work.

  6. #6
    Join Date
    Jan 2007
    Location
    Bournemouth, England
    Posts
    99
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    but if you changed the home page to index.php (it will still be counted as a homepage), you could use this code:

    PHP Code:
    <?PHP include ("http://www.killconrad.com/blog/index.html"?>
    inside the div.

  7. #7
    Join Date
    Jul 2006
    Location
    Canada
    Posts
    2,581
    Thanks
    13
    Thanked 28 Times in 28 Posts

    Default

    URL File Access has to be enabled on your server for http protocols.. Local files are fine:
    Code:
    <?php include "index.html"; ?>
    - Mike

  8. #8
    Join Date
    Jan 2007
    Location
    Bournemouth, England
    Posts
    99
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    oh, lol. I didn't know about URL file access, I tried it and it worked on my host so I thought that it would be the same for everyone. So yes llorax use:

    <?php include "index.html"; ?>

    (I missed out the ; as well.)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •