added ajax for both buy and sell