html and iframes

Posted on 2004-11-06
Last Modified: 2010-04-09

the problem is that I am using 2 DIV's and one with an iframe, this way i can hide one or the other depending on if i am displaying a still image or the vitual tour(VT). The problem is when i click on the vitual tour, it leaves a gap between the contact and VT, but when i click on a still image there is no gap (don't worry that the still images are not linked). IE does not leave that bad of a gap, but motzilla leaves a huge gap, is there any fox to get rid of the gap or is it a problem of the browsers.
Question by:javajamminman
    LVL 5

    Expert Comment

    Hi javajamminman,

    I noticed something in your JavaScript.  Change this:
    document.all['imagearea'].style.display = '';
    to this:
    document.all['imagearea'].style.display = 'block';

    Please wait while I look at the main problem...

    LVL 5

    Accepted Solution

    OK, I think I have it figured out.  Your iframe is taller than its contents.
    Change your iframe height from 350 to 325 like so:

    <iframe src="applet.asp?file=img_0009_0360.jpg" width="350" marginwidth="0" height="325" scrolling="no" frameborder="0" vspace="0" id="appletiframe">


    Author Comment

    Yeah, after you pointed me in the right direction, my applet had a hieght of 325 but my Iframe was 350, so thats why it had the gap.....All is well now,
    LVL 5

    Expert Comment


    Glad I could help out.

    I am curious: why did you give me a grade of B?
    I didn't just "point you in the right direction;" I gave you the exact answer you needed.


    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    Join & Write a Comment

    Introduction HTML checkboxes provide the perfect way for a web developer to receive client input when the client's options might be none, one or many.  But the PHP code for processing the checkboxes can be confusing at first.  What if a checkbox is…
    Someone recently asked me about how to display a progress indicator on a page while an iframe is loading. And I remember when I first came across this myself. It was a bit tricky to get my head around, but really, it's very simple. The most impor…
    In this tutorial viewers will learn how to style transparent/translucent elements using alpha transparency in CSS Start with a normal styled element, such as a div.: Define its "background-color" property as "rgba (255, 255, 255, .5): The numbers in…
    The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)

    728 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    19 Experts available now in Live!

    Get 1:1 Help Now