PHP can make your pages dynamic on the server side, meaning that, depending on certain circumstances or input, the page will look different. For instance, if I’m logged in on a site, the page may have my name on it, or my account information. That page is built when my browser requests the information. It’s built ‘on the fly’ based on my login information. It’s not a static page, hard-coded in HTML. It changes based on what is asked for by my browser.
Many times we need to make our web pages dynamic on the client side of things. In other words, we need to do something dynamically on the browser side of things – your local computer – instead of at the server side. For instance, if I enter something in a form, I have to submit the form, wait for the PHP code to check to see if what I entered is correct and then send me the results. If my browser were somehow able to check what I entered before it sends it to the website, it could speed things up considerably.