https://www.youtube.com/watch?v=tTBzJMcOU6w

Above link is youtube video of ajax tutorial and it is very useful. but i found one error. code works when we pressed submit button but it displays whatever we type in text in URL when we press enter button instead of submit button. Is there any solution?