[Javascript] IGNORE PREV. READ THIS PLS> Any creative way to pullhtml content same wayjsfiles are pulled

David T. Lovering dlovering at gazos.com
Mon Mar 31 11:40:39 CST 2003


DEV --

  The trick is to NOT include width or height specifications in the IFRAME declaration.
If you include either, you have to include both or bad things happen.  If your window is
physically smaller than the object you are viewing, you get scrollbars.  Period.  [In Java
there are methods to force "inner windowing" which gives you a peephole effect, and you
can drag the center of focus around as needed -- much like Acrobat Reader].  If the HTML
referenced by the IFRAME will fit in the physical window, then you don't get scrollbars
by virtue of this method, and if you do it is only on the "outer" window, not the one in
which the IFRAME contents appear.  I've used this extensively on all flavors of IE, and
haven't had any problems.  [Netscape is still a little funky with IFRAME declarations,
and I can't speak for Opera, Galeon, etc.].  If you want to suppress the outer scrollbars
altogether no-matter-what, you'll have to resort to methods that transcend this thread.

  If you are picky about the viewing size of the IFRAME, put the height/width parameters in
the BODY declaration of included HTML object, but avoid putting them into the IFRAME invocation.

  You are correct (insofar as I know) about OBJECT -- you MUST include the dimensions at the
creation, or else you get zero.  Just another reason to detest OBJECT for anything that doesn't
do its own window geometry management.

  -- Dave Lovering

DEV wrote:
> 
> Thanks David,
> 
> <YourQuote>
> '
> '
> '    <iframe name='blah-blah-blah' src='myFile.html' scrolling='no'>, and
> make
> '    sure that the BODY declaration of myFile.html also has scrolling='no'
> in it, your
> '    inserted window will not have scrollbars.
> '
> 
> </YourQuote>
> 
> That's true, however, if the myFile.html is lengthy, would not the iframe
> innercontents be cut and without having the scrollbars, user must be a geek
> to drag that area with mouse to scroll down. As far as I know, there is no
> way that the iframe height when set to a some magical value, it will be
> allow itself to show the entire content of its src without needing the
> scroll bars for its content to be reachable.
> 
> I am not an expert on "OBJECTS" however, but ASKAIK those too would require
> a height definition to be set at their declaration time.
> 
> However, with server include or src='script.js ' approaches will never
> require a preset height.
> 
> I was hoping that something like below would be available in the HTML specs.
> 
> <div id="/myFile.htm"></div>
> 
> _______________________________________________
> Javascript mailing list
> Javascript at LaTech.edu
> https://lists.LaTech.edu/mailman/listinfo/javascript


More information about the Javascript mailing list