When a browser receives a document, it contains javascript in it. This javascript makes the html document dynamic on client side. Why do we need to send http request from javascript ? Because, if an http request is to be sent to server, we can click link or button on the html doc. Does it have to do something with XML document ? How is this rerquest sent ? Does it go automatically or a butoon is required to be clicked ?

Please explain this.