as far as i know there are cross domain restictions that wont allow you to get content from an external url and in order to overcome this , we use server side scripts.
Im wondering how facebook/google overcomes these restrictions and with a javascript code manage to generate their like box with a simple code like this :
<div id="fb-root"></div>
<script>(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&appId=254277301328504";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
the reason im asking that is because im building a virtual chat bot and want the users to just use a simple javascript to generate the bot in their site(on external domain without them having to use a serverside scripting)
Thanks