add ajax interface
Merge pull request #3 from knightingal/1411171

add ajax interface