*SOLVED*
It's working as below:
HTML Code:
<script type="text/javascript">
(function() {
var s = document.createElement('SCRIPT'), s1 = document.getElementsByTagName('SCRIPT')[0];
s.type = 'text/javascript';
s.async = true;
s.src = '/clientscript/vbulletin-core.js?v={vb:raw vboptions.simpleversion}';
s1.parentNode.insertBefore(s, s1);
})();
</script>
facebook java doesn't work with the following function, probably because the js of facebook it's call via vb raw before the main code so function is loaded normall but connectivity avoided.!!
If you want to use the defer js, for all your java files used above code. if your using cdn it will not work, so you need to replace the source with the exactly address, for example::
Code:
'http://pullzone-anymvs.netdna-cdn.com/clientscript/vbulletin-core.js?v={vb:raw vboptions.simpleversion}'
at the end if you have cache control you must remove the query from the actual js file, so need to remove
?v={vb:raw vboptions.simpleversion} from all your js file after you enable cache header..
Note: This is working for me and it's a good idea to used it especially if your running on a simple hosting. it will not make your side load 10 times faster but it will reduce the time load of js files at all, especially for users that they use IE as browsing.
TIP: load your css files as
HTML Code:
<link rel="stylesheet" type="text/css" href="http://pullzone-anymvs.netdna-cdn.com/clientscript/vbulletin_css/style00014l/additional.css" />
don't used vb raw variables, are very lag and have no sense!!