Can anyone tell me how to reload or refresh a whole page after clicking a follow button on Visualforce Page? My VFP as follows;

       funtion reload(){
           window.location.reload( true );

   <apex:repeat value="{!userList}" var="user">
      <apex:outputText value="{!user.Name}" /><chatter:follow entityId="{!user.id}" onComplete="reload();"/>


But the above code doesnt perform very well! So What Ive to modify in that page?

Thanks in advance Karthick


The code below should work

<apex:repeat value="{!userList}" var="user">
  <apex:outputText value="{!user.Name}" /><chatter:follow entityId="{!user.id}" onComplete="window.location.reload();"/></apex:repeat>


  • No that s y am asking – user3332076 Oct 29 '14 at 10:58
  • I tried and it worked for me. I used this code by replacing the list to accounts – Saranya Oct 29 '14 at 11:07
  • This is the code I used <apex:page standardController="Account"> <apex:form> <apex:repeat value="{!Account.Contacts}" var="user"> <apex:outputText value="{!user.Name}" /><chatter:follow entityId="{!user.id}" onComplete="window.location.reload();"/> </apex:repeat> </apex:form> </apex:page> – Saranya Oct 29 '14 at 11:09
  • Oh ..Can you share your code to my mail id(pskarthick.sonacse23@gmail.com) – user3332076 Oct 29 '14 at 11:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.