Note that there are some explanatory texts on larger screens.

plurals
  1. POload external js file for social buttons not working inside a refreshed div using .load
    primarykey
    data
    text
    <p>I have a box that has news container, social buttons container and comment box container. The box has fixed height so i could not use .append instead i want to refresh that box. The problem is the social buttons is not working when i use .load in the box because it is using external .js file. Is this possible?</p> <p>Here is my box:</p> <pre><code>&lt;div class="pin-box" id="pinbox_&lt;?php echo $row['articles_id'];?&gt;"&gt; &lt;div class="box1"&gt; &lt;?php //Script that will echo articles ?&gt; &lt;hr class="art_line"&gt; &lt;div class="social_button" id="social_&lt;?php echo $row['articles_id'];?&gt;"&gt; &lt;span class='st_facebook_large' st_url='&lt;?php echo base_url(); ?&gt;index.php/be_informed/show/&lt;?php echo $row['articles_id']; ?&gt;' displayText='Facebook'&gt;&lt;/span&gt; &lt;span class='st_twitter_large' st_url='&lt;?php echo base_url(); ?&gt;index.php/be_informed/show/&lt;?php echo $row['articles_id']; ?&gt;' displayText='Tweet'&gt;&lt;/span&gt; &lt;span class='st_linkedin_large' st_url='&lt;?php echo base_url(); ?&gt;index.php/be_informed/show/&lt;?php echo $row['articles_id']; ?&gt;' displayText='LinkedIn'&gt;&lt;/span&gt; &lt;span class='st_googleplus_large' st_url='&lt;?php echo base_url(); ?&gt;index.php/be_informed/show/&lt;?php echo $row['articles_id']; ?&gt;' displayText='Google +'&gt;&lt;/span&gt; &lt;/div&gt; &lt;div id="space"&gt;&lt;/div&gt; &lt;div id="beinformed_comment"&gt; &lt;?php //Script that will echo comments ?&gt; &lt;/div&gt; &lt;/div&gt; &lt;/div&gt; &lt;script type="text/javascript" src="http://w.sharethis.com/button/buttons.js"&gt;&lt;/script&gt; &lt;script type="text/javascript"&gt; stLight.options({publisher: "751d0899-1764-4d1f-aac0-1bf112ad5cfd", doNotHash: false, doNotCopy: false, hashAddressBar: false }); &lt;/script&gt; </code></pre> <p>Here is my Jquery code(I am using 1.4.2):</p> <pre><code>$('.comment_button_article').live("click",function() { var ID = $(this).attr("id"); var comment= $("#ctextarea"+ID).val(); var user_id= $("#user_id_"+ID).val(); var dataString = 'comment='+ comment + '&amp;msg_id=' + ID + '&amp;user_id=' + user_id; if(comment=='' | comment=='Enter your comment here') { alert("Please Enter a Comment"); } else { $.ajax({ type: "POST", url: "comment_ajax.php", data: dataString, cache: false, success: function(html){ $('#pinbox_'+ID).load('&lt;?php echo base_url(); ?&gt;index.php/be_informed/index #pinbox_'+ID); } }); } return false; }); </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload