ajax post functionality started to work