How to hide page or set invisible during page loading

46 views
Skip to first unread message

David

unread,
Jul 21, 2016, 8:46:58 AM7/21/16
to GWT Users
I used GWT to change original PC html page layout to mobile layout without accessing original html source code. During page loading, I can see the original html page PC layout. I want to hide it or make it invisible  until new layout is formed during page loading. How do I achieve it? Some of them are <frameset> pages. During page loading, I can access HTMLDocument. Once I get HTMLDocument.body, it is too late to do something because original PC layout is already presented.

David

Gilberto

unread,
Jul 21, 2016, 9:06:33 AM7/21/16
to GWT Users
Without changing the host page there's little you can do in GWT to avoid showing the original page: the page is rendered while the GWT module itself is loading. So you can't execute GWT code without loading it first.

If you can change the the host page, you could add a script to do some logic before GWT loads.

Thomas Broyer

unread,
Jul 21, 2016, 10:02:10 AM7/21/16
to GWT Users


On Thursday, July 21, 2016 at 3:06:33 PM UTC+2, Gilberto wrote:
Without changing the host page there's little you can do in GWT to avoid showing the original page: the page is rendered while the GWT module itself is loading. So you can't execute GWT code without loading it first.

If you can change the the host page, you could add a script to do some logic before GWT loads.

Actually, with a custom linker, you could add some custom JS to the *.nocache.js, but that won't help if the <script> is at the bottom of the <body>
Reply all
Reply to author
Forward
0 new messages