Anybody asking this question should generally be starting with an XMPP library that implements everything they need already.
It still deserves an answer though!
XMPP stands for eXstensible Messaging and Presence Protocol. The 'extensible' part is important. XMPP is based around XML, a data format that supports a concept known as namespacing.
Through namespacing, you can add bits to XMPP that are not defined in the original specifications. This is important because the XMPP specification deliberately describes only a set of core things like:
- How a client connects to a server
- Encryption (SSL/TLS)
- Authentication
- How servers can communicate with each other to relay messages
...and a few other basic building blocks.
Once you have implemented this stuff, you have an XMPP client and can send any kind of data you like! But that's also a problem.
For example, perhaps you decide that you want to include formatting in a message (bold, italic, etc.) which is not defined in the core XMPP specification. Well, you can make up a way to do that, but unless everyone else does it the same way as you, no other software will be able interpret it (they will just ignore namespaces they don't understand).
So the XMPP Standards Foundation (XSF) publishes a series of extra documents, known as XMPP Enhancement Proposals (XEPs). In general each XEP describes a particular activity (from message formatting, to file transfers, multi-user chats and many more), and they provide a standard format for everyone to use for that activity.
You mentioned Strophe.js. This is a "low-level" library which expects you to implement the extensions that you need yourself. I don't consider most of them hard, but you would have to spend some time learning if you are unfamiliar with bidirectional protocols, basic XML/DOM concepts, and so on. The Strophe.js author wrote a good book which can also serve as an introduction to XMPP web development, Professional XMPP Programming with Javascript and jQuery.
This question is also answered in some detail in XMPP: The Definitive Guide, which also provides an extensive overview of the core protocol and common extensions.
For further online reading of XMPP, this StackOverflow question may give some pointers: "Good tutorials on XMPP?".
Hope this helps!