I have this script which I put on top of the GWT nocache.js
<head>
<script type="text/javascript" language="javascript">
(function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return;
js = d.createElement(s); js.id = id;
js.src = "//connect.facebook.net/en_US/all.js#xfbml=1";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));
</script>
<script type="text/javascript" language="javascript"
src="app/app.nocache.js"></script>
</head>
<body>
<div id="fb-root"></div>
<div id="rootPanel"></div>
</body>
And on one of the page of the my site (which I use Errai-UI)
This is added on the gwt "page":
HTMLPanel likebox = new HTMLPanel("<div class='fb-like-box'
datahref='http://www.facebook.com/platform' data-width='595'
data-show-faces='true' data-stream='true' data-header='true'></div>");
likepanel.add(likebox); // Add to the SimplePanel
The problem I am facing is that in my GWT application, when the site
lands on the "page" where this panel is injected, the Facebook like box
doesn't get rendered, even if I look at the DOM, the `<div
class='like-box' ...>` is there in the DOM tree.
What works is that I need to do a full page refresh (in DevMode), on the
currect page: example: `/mysite#PageWithFBDiv`
Also, the page refresh trick only works in DevMode but fails to do the
trick when compiled.
--
You received this message because you are subscribed to the Google Groups "Google
Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.