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

1 Answer 1


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 Commented Oct 29, 2014 at 10:58
  • I tried and it worked for me. I used this code by replacing the list to accounts
    – Saranya
    Commented Oct 29, 2014 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
    Commented Oct 29, 2014 at 11:09
  • Oh ..Can you share your code to my mail id([email protected]) Commented Oct 29, 2014 at 11:21

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .