document.write('
Data hosted with ♥ by Pastebin.com - Download Raw - See Original
  1. <script type=\'text/javascript\'>
  2. //<![CDATA[
  3. // Trim popular post snippets right using jQuery / MS-potilas 2012
  4. // Put this code in a html/javascript gadget (after popular posts gadget), or before </body>.
  5. // See http://yabtb.blogspot.com/2012/01/trim-blogger-popular-post-snippets.html
  6. $(\'.popular-posts ul li .item-snippet\').each(function(){
  7.   var txt=$(this).text();
  8.   var j=txt.lastIndexOf(\' \');
  9.   if(j>42)
  10.      $(this).text(txt.substr(0,j).replace(/[?,!\\.-:;]*$/,\'...\'));
  11. });
  12. //]]>
  13. </script>
');