Hi Félix,

> This is rather easy in pure JS. All you have to do is to remove all
> elements you don't want/need (such as <script>) and then use
> `document.documentElement.innerHTML` or something similar. If you
> wanted to do this on a larger scale, you could use/embed XulRunner in
> some way and run a similar piece of JS from that.
> 
> You might also be able to hook directly into the engine to the same
> effect with possibly better performance. Note that scripts on the page
> might be designed to be used by the user, not ran all at once on load,
> so the page would be non-functional through your process.

That is great news! I know that this might break the functionality of some 
sites. As the intended
purpose is to provide a "preview", we would try to catch all onClick events, 
and then forward the
user to the "real" page. Moreover, all simple GET and POST requests should lead 
to loading the
"real" site with those arguments scripts that we embed into the site by 
ourselves. Does this sound
reasonable?

> On another note, I think what you are proposing is already implemented
> in a way by Opera for their mobile/embedded browser.

Great, this would be a way to explore the possibilities of such a filtering, 
e.g. to see how Opera
tries and/or succeeds to keep the site functionality. Thank you for this hint!

Best regards

Rolf

-- 
Rolf Wendolsky

Phone:     +49.911 2001 8914
Fax:       +49.941.604889 64
Mobile:    +49.175.1636283
eMail:     mailto:[email protected]
PGP/GPG:   0x953CC668 
(https://anonymous-proxy-servers.net/downloads/gpg/wendolsky.asc)
Skype:     jondonym
Jabber:    [email protected]/Home
Web:       http://www.jondos.com

JonDos GmbH
Firmensitz: Bruderwöhrdstraße 15b, 93055 Regensburg
Registergericht: Amtsgericht Regensburg, HRB 10532
Umsatzsteuer-Identifikationsnummer: DE814839010
Geschäftsführer: Rolf Wendolsky, Thomas Dumler
_______________________________________________
dev-tech-layout mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-tech-layout

Reply via email to