difference between .html() and .load()

html, jquery

Solution

`.load` is a shorthand for doing an asynchronous request and putting the contents in the element you are calling this on.

`.html` is a method to put the argument to it as the contents of the element you are calling this on.

You want to use `.load`.

Problem

I want to load another php or html file inside a div. Should I use `.load()` or `.html()`? What is the difference?

Original source