else { if(fp.viewer.getField(opensocial.Person.Field.PROFILE_URL)== foot.profile) { putViewerlink(foot.myVisit1); } } if (i < noOfMembs) { //if (foot.name.length < 16) // memName = foot.name; //else // memName = foot.name.substr(0,15) + '<br>' + foot.name.substr(15,foot.name.length - 15); memName = foot.name; html += '<tr><td valign=top><img src = "' + foot.thumbnail + '" width=' + imgw + ' height=' + imgw + '></td>'; html += '<td valign=top><a href="' + foot.profile + '" target="_top" >'; html += '<span style="font-size:13px;color:' + linkColor +';font-family:' +fontFamily +';"><b>' + memName + '</b></a></span></td><td valign=top><span style="font-size:12px;font-family:' + fontFamily +';">'+foot.myVisit1 +' visits</span>'; html += '</td></tr>'; } //html += '<img src="' + foot.thumbnail + '" width=36 height=36>'; //html += '<a href="' + foot.profile + '">' + foot.name + '</a><br>'; //html += '<a href="' + foot.myVisit1 + '">Link</a>'; }; if (fp.viewer == null) { // var mmsg = new gadgets.MiniMessage(); // mmsg.createDismissibleMessage('Please Sign in for your visit to be counted'); vhtml = '<span style="font-size:11px;color:' + textColor +';font-family:' +fontFamily +';">Please Sign in for your visit to be counted</span>'; $('#viewerDiv').html(vhtml); } else { var visits =document.getElementById('hiddenlink').value; var v1 =parseInt(visits); //v1 = v1 + 1; //vhtml = '<span style="font-size:12px;">Welcome ' + fp.viewer.getDisplayName() + '</span><br>'; vhtml = '<a href="'+fp.viewer.getField(opensocial.Person.Field.PROFILE_URL); vhtml += '" target="_top"><span style="font-size:13px;color:' +linkColor +';font-family:' + fontFamily +';"><b>You</b></span></a> <span style="font-size:13px;color:' + textColor +';font-family:' +fontFamily +';">(' + v1 + ' Visits before)</span><hr>' ; $('#viewerDiv').html(vhtml); saveLink(); } html = '<table>' + html +'</table>'; html += '<br>'; $('#myVisits').html(html); $('#myVisits li').css('background-color',gadgets.skins.getProperty('ALTERNATE_BG_COLOR')); gadgets.window.adjustHeight(); } }; function putViewerlink(link1) { document.getElementById('hiddenlink').value= link1; } function saveLink() { var visits =document.getElementById('hiddenlink').value; var v1 = parseInt(visits); v1 = v1 + 1; var foot = { 'id': fp.viewer.getId(), 'name': fp.viewer.getDisplayName(), 'thumbnail': fp.viewer.getField(opensocial.Person.Field.THUMBNAIL_URL), 'profile': fp.viewer.getField(opensocial.Person.Field.PROFILE_URL), 'myVisit1': v1 }; var myVisit1 =gadgets.json.stringify(foot); var req = opensocial.newDataRequest(); req.add(req.newUpdatePersonAppDataRequest(opensocial.IdSpec.PersonId.VIEWER,'myVisit', myVisit1)); req.send(); } </script> <script type="text/javascript"> gadgets.util.registerOnLoadHandler(fp.init); </script> <div id="header" class="header"><span style="font-size:13px;"><b>Top 10 Members</b></span></div> <div id="viewerDiv"></div> <div id="myVisits"></div> <div id="footer"> <a href="http://blog.xmlgadgets.com/google-friend-connect/top-10-members-google-friend-connect-gadget/?utm_source=top10&utm_medium=GFC&utm_campaign=Gadget"target="_blank"><span style="font-size:11px;">Get This!</span></a> </div> <input type=hidden id=hiddenlink value="0"><script type="text/javascript">var gaJsHost = (("https:" ==document.location.protocol) ? "https://ssl." :"http://www.");document.write(unescape("%3Cscript src='" + gaJsHost+ "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));</script><script type="text/javascript">try {var pageTracker = _gat._getTracker("UA-4747275-3");pageTracker._trackPageview();pageTracker._trackEvent('Top10', 'Viewed');} catch(err) {}</script> ]]> </Content></Module>Como adicionar este gadget para um Blogger do site alimentado blog /?Clique aqui para adicionar "Top 10 Membros" gadget para seu blog blogger.Caso contrario,1. Va para a pagina de layout do seu blog.2. Clique em "Adicionar gadget" 3. Clique em "Adicionar o seu proprio" 4. Dar a url gadget como http://xmlgadgets.com/ig/top10.xml e salvar.Como adicionar este gadget para nao-Blogger sites?1. Acesso ao Google Friend Connect , e selecione o site que voce deseja adicionar o gadget.2. Clique em "Gadgets Social"3. Clique em "Todos os Gadgets" tab.4. Localize "Top 10 Membros" gadget e clique em "Get esse gadget" var addthis_config = {"data_track_clickback":true};