Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7591663
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T20:42:25+00:00 2026-05-30T20:42:25+00:00

Possible Duplicate: How to render a plugin added dynamically? This is my code :

  • 0

Possible Duplicate:
How to render a plugin added dynamically?

This is my code :

HTML

<div id="fb-root">
<fb:like href="www.google.it" send="false" layout="button_count" width="auto" show_faces="true"></fb:like>
<div id="newFB"></div>
<a href="#" id="showFacebook">Add new "I Like" and refresh</a>

jQuery

function renderFB() {
    (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/it_IT/all.js#xfbml=1"; fjs.parentNode.insertBefore(js, fjs); } (document, 'script', 'facebook-jssdk'));
}

renderFB();

$("#showFacebook").click(function() {
    $('#newFB').html('<fb:like href="www.google.it" send="false" layout="button_count" width="auto" show_faces="true"></fb:like>');
    
    renderFB();
});

what I’d like to do is load every FB plugins on page load; then, in some moments, append a new plugins and re-render them all. Or, if possible, only the last inserted.

Is it possible? And how can I do it?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T20:42:26+00:00Added an answer on May 30, 2026 at 8:42 pm

    Just try IFRAME instead of XFBML..

    like,

    $('#newFB').html('<iframe src="//www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.google.it&amp;send=false&amp;layout=button_count&amp;width=450&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;font&amp;height=21" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:450px; height:21px;" allowTransparency="true"></iframe>');

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Possible Duplicate: Why is it a bad practice to return generated HTML instead of
Possible Duplicate: Zend Framework - multiplate navigation blocks I'm trying to make breadcrumbs render
Possible Duplicate: Which CPAN module would you recommend for turning HTML into plain text?
Possible Duplicate: Emacs: same buffer, two windows, one narrowed, one not I'd like to
Possible Duplicate: Why not use tables for layout in HTML? Under what conditions should
Possible Duplicate: How do I calculate someone's age in C#? Maybe this could be
Possible Duplicate: Weird “406 not acceptable” error I've been stuck on this ALL DAY!
Possible Duplicate: render the values of controllers to view I am newbie to php
Possible Duplicate: Render a view as a string Hi I am wondering is it
Possible Duplicate: How to render PDF in Android Does any one know how to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.