Im new to Ruby on Rails.
I am using ajax for sorting rows in Ascending / Descending order and its working fine.
Sorting is done by clicking column name in rows list.
But i verified my running area in firebug console in firefox.
At first time clicking sort(column name) my jquery calling only once.
After i used sorting means my jquery file calling two times.
Again i used sorting means jquery calling 4 times.
It calling like 1-time,2-time,4-time,8-time like wise.
If I refresh the page then it starts this issue from 1,2,4,8 times..like..
Can any one Help…
Thanks in advance.
Actually the page not refreshing.The function only running more than one time.
I declared controlLoop global variable value as 0.
If SortData function runs, then the controlLoop value will be increment.
if controlLoop value is not equal to 0, then the function will stop working on Sorting Function.
I know this is wrong way. But this is not final solution. If i get any solution regarding this surely i will update.