Tab Atkins Jr.
jackalmage at gmail.com
Fri Oct 16 06:11:12 PDT 2009
On Fri, Oct 16, 2009 at 6:16 AM, Markus Ernst <derernst at gmx.ch> wrote:
> Aryeh Gregor schrieb:
>> On Thu, Oct 15, 2009 at 3:49 AM, Nelson Menezes
>> <flying.mushroom at gmail.com> wrote:
>>> As an aside, there is a reason why AJAX has become so popular over the
>>> past few years: it solves the specific UI-reset issue that is inherent
>>> in full-page refreshes.
>> I'm trying to think what a solution to this would look like. Maybe
>> something like:
>> <static id=foo>Some stuff that doesn't change on page load...</static>
>> Changeable page content
>> <static id=bar>Some more stuff that doesn't change...</static>
> Interesting idea! Anyway it introduces some consistency problems to solve,
> Page1.html contains:
> <static id="foo">I eat meat</static>
> and links to page2.html, which contains:
> <static id="foo">I am a vegetarian</static>
> So page2.html looks different whether it is called from the link in
> page1.html, or directly via a bookmark, external link, or manual URI input.
Nod. This seems like a big problem.
> This could be solved if "static" elements have no content on their own, but
> retrieve it from an external source. The identifyer is then not the id
> attribute, but the source. This could be done with a src attribute on the
> <static> element. But I assume an easier implementation would be adding a
> "static" attribute for the <iframe> element, indicating that the iframe
> contents should not be reloaded.
As well, if <iframe> is reused, it should probably automatically be
<iframe seamless> so that all navigation applies to the upper page, it
grabs styles from the upper page, etc. (Or perhaps it should just be
recommended that <iframe static seamless> be used in most
The <iframe> solution is also somewhat better wrt scripting the
content inside. If you're trying not to redraw anything in <static>,
what happens to scripts that have added listeners and such to the
content? (Frex, to implement an accordion or treeview.) The original
page is going away, and you don't want to accidentally apply the
listeners multiple times. Using <iframe>s, you can do the scripting
in the framed page, so nothing goes away between pageloads or tries to
apply itself multiple times.
More information about the whatwg