开发者

Facebook Comment Plugin is not working with smarty template

开发者 https://www.devze.com 2023-01-22 20:34 出处:网络
Th开发者_如何学Goe facebook comment plug in is not working with smarty template. The code I am using is given below

Th开发者_如何学Goe facebook comment plug in is not working with smarty template. The code I am using is given below

<div id="fb-root"></div> {literal}<script src="http://connect.facebook.net/en_US/all.js#appId=APP_ID&amp;xfbml=1"></script>{/literal} <fb:comments width="425"></fb:comments>

Please check this and let me know if there is any solution for this

Thanks In Advance Rose


The issue is most likely because of the order in which this template loads on the page. You are most likely going to need to manually initialize the XFBML on your page for the tag to render. This is probably beyond what a template engine is going to be able to do. You are going to need to call FB.init(xfbml:true); after the template has loaded on the page. Also, change the script reference to

<script src="http://connect.facebook.net/en_US/all.js"></script>

The initilization call should occur only after the above script is loaded.

<script>
FB.init({xfbml:true});
</script?
0

精彩评论

暂无评论...
验证码 换一张
取 消