Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.javascript > #33404

Re: Instead of <iframe onload=...

From Dr J R Stockton <reply1700@merlyn.demon.co.uk.invalid>
Newsgroups comp.lang.javascript
Subject Re: Instead of <iframe onload=...
Date 2017-05-24 23:18 +0100
Organization Home
Message-ID <ZktfsUU9agJZFwWw@invalid.uk.co.demon.merlyn.invalid> (permalink)
References (1 earlier) <ofmrnu$sc9$1@news.albasani.net> <b06552ca-cd04-4314-8dea-76a7630b4058@googlegroups.com> <hogR$$KPILIZFwpJ@invalid.uk.co.demon.merlyn.invalid> <ofqlst$rik$1@news.albasani.net> <2c839093-3b07-40fc-9cda-7ffd9f92faa9@googlegroups.com>

Show all headers | View raw


In comp.lang.javascript message <2c839093-3b07-40fc-9cda-7ffd9f92faa9@go
oglegroups.com>, Sun, 21 May 2017 11:46:39, Dr J R Stockton
<J.R.Stockton@physics.org> posted:

> ...

>While writing the above, it occurred to me that it would be easy
>to set the size of the infant iframe to the value of DefaultHeight
>provided, and adjust it later if the right height becomes known.
>Then, for readers whose browser window is a sensible number of em
>units wide, jumping will be replaced by minor hopping.


Yes.  But I have at last realised that this JavaScript re-sizing can
never work under all necessary circumstances.

I want the pages to display well when read (or copied) from a transfer
USB memory stick, using an ordinary PC with only what Windows supplies,
though maybe using another browser instead.  And I'd rather not rely on
it having a UK keyboard, or a keyboard driver that matches the keyboard.

Therefore I cannot rely on using
        Iframe.contentDocument.documentElement.scrollHeight
because when reading from a local drive Chrome, at least, considers that
to be forbidden by the Same Origin Policy.

Therefore I intend, as author, to continue using Firefox, in which the
Same Origin Policy is more sensibly implemented, with "Iframe includes"
and "contentDocument", but with the Iframe height initially being set to
an initially suitable amount.  Provided that the refusal of
contentDocument is silently trapped, that version will be non-ideal but
distributable.

And I have it in mind to write a pre-processor, in Windows Script Host
JavaScript, which will read file ????WXYZ.HTM, read and insert the
includes that it contains, recursively, and write file ????WXYZ.$HTM;
the (MS-DOS Batch) transfer program can easily be persuaded to omit the
"$".

-- 
 (c) John Stockton, Surrey, UK.  ¬@merlyn.demon.co.uk   Turnpike v6.05   MIME.
 Merlyn Web Site <                       > - FAQish topics, acronyms, & links.

Back to comp.lang.javascript | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Instead of iframe onload? Dr J R Stockton <J.R.Stockton@physics.org> - 2017-05-18 05:40 -0700
  Re: Instead of iframe onload? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2017-05-18 15:07 +0200
    Re: Instead of iframe onload? Dr J R Stockton <J.R.Stockton@physics.org> - 2017-05-18 08:11 -0700
      Re: Instead of iframe onload? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2017-05-18 18:09 +0200
        Re: Instead of iframe onload? Andrew Poulos <ap_prog@hotmail.com> - 2017-05-19 12:36 +1000
          Re: Instead of iframe onload? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2017-05-19 09:15 +0200
            Re: Instead of iframe onload? Andrew Poulos <ap_prog@hotmail.com> - 2017-05-19 18:12 +1000
              Re: Instead of iframe onload? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2017-05-19 11:47 +0200
  Re: Instead of iframe onload? Joao Rodrigues <groups_jr-1@yahoo.com.br> - 2017-05-19 02:44 -0700
  Re: Instead of iframe onload? Martin Honnen <martin.honnen@gmx.de> - 2017-05-19 15:25 +0200
    Re: Instead of iframe onload? Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2017-05-19 18:11 +0200
    Re: Instead of iframe onload? Dr J R Stockton <J.R.Stockton@physics.org> - 2017-05-19 14:30 -0700
      Instead of <iframe onload=... Dr J R Stockton <reply1700@merlyn.demon.co.uk.invalid> - 2017-05-20 22:15 +0100
        Re: Instead of <iframe onload=... Stefan Weiss <krewecherl@gmail.com> - 2017-05-21 02:10 +0200
          Re: Instead of <iframe onload=... Dr J R Stockton <J.R.Stockton@physics.org> - 2017-05-21 11:46 -0700
            Re: Instead of <iframe onload=... Dr J R Stockton <reply1700@merlyn.demon.co.uk.invalid> - 2017-05-24 23:18 +0100
          Re: Instead of <iframe onload=... Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2017-05-21 23:22 +0200
            Re: Instead of <iframe onload=... Stefan Weiss <krewecherl@gmail.com> - 2017-05-22 00:39 +0200
              Re: Instead of <iframe onload=... Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2017-05-22 01:38 +0200
                Re: Instead of <iframe onload=... Stefan Weiss <krewecherl@gmail.com> - 2017-05-22 02:19 +0200
                Re: Instead of <iframe onload=... Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2017-05-22 02:35 +0200
                Re: Instead of <iframe onload=... Stefan Weiss <krewecherl@gmail.com> - 2017-05-22 12:54 +0200
                Re: Instead of <iframe onload=... Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2017-05-22 15:37 +0200
                Re: Instead of <iframe onload=... Stefan Weiss <krewecherl@gmail.com> - 2017-05-22 18:23 +0200
                Re: Instead of <iframe onload=... Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2017-05-23 14:15 +0200
                Re: Instead of <iframe onload=... Stefan Weiss <krewecherl@gmail.com> - 2017-05-23 15:56 +0200
                Re: Instead of <iframe onload=... Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2017-05-23 18:41 +0200
        Re: Instead of <iframe onload=... Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2017-05-22 03:27 +0200

csiph-web