These elseif's are useless, but not a problem. They are only usefull if same values compared in more than one if or with a complete else on end.
If lastData is correct, there must be something wrong with int - string use, is the global int and you int(AJAX.LastData) or int(isMember) on compare?
You also can change the second compare value to string...