Dynamically reparse sharing buttons on ajax generated page
-
I am using a custom ajax single-page app to browse my wordpress website.
The website has ngfb/ngfb-pro plugin installed.The initial page (loaded without ajax) displays the sharing buttons correctly. The ngfb script runs asynchronously and prints out linedin, g+, twitter and fb like/sharing button iframes correctly.
However when I reload page fragments through ajax the sharing button iframes do not get reparsed.
How do I dynamically reparse sharing buttons when loading pages with an ajax request?
ngfb generates the buttons just fine on the initial load.
But not on any pages loaded through ajax.I found these solutions/hacks for fb and gplus:
FB.XFBML.parse(document.getElementById(‘facebook-content-buttons-post-XXX’)); gapi.plusone.go();
which I can run on any successful ajax request, But couldn’t find any for twitter and linkedIN
Is there a way to achieve this using the plugin?
And if not could you tell me which scripts to run for the other networks?Thank you,
apedogThe page I need help with: [log in to see the link]
- The topic ‘Dynamically reparse sharing buttons on ajax generated page’ is closed to new replies.