In slightly more formal terms, truth is not preserved across an intensional operator. By this I mean something that converts a statement of fact into a statement of an intensional state: typically a mental state such as belief.

('Intension' and 'intention' are pronounced the same but mean different things. An intention is one kind of mental attitude to a state: that of wanting or planning to see it occur in the future; so intention may be an example of intension. However, inevitably, the familiar spelling 'intention' is often used to mean the completely different idea of intension, in which case you just have to bear in mind that philosophers are using it as a term of art much at variance from its usual meaning.)

For example, "Oslo is the capital of Norway" and "Copenhagen is the capital of Denmark" are plain extensional statements. Symbolize them by Cap(O, N) and Cap(C, D). Belief is an operator that turns this fact into another fact: if Bush believes X, then that's a fact about Bush. Let's symbolize it Bel(B, X). But the X in this proposition is not a simple name like 'Copenhagen'; rather it is itself another proposition.

So Bel(B, Cap(O, D)) means "Bush believes that Oslo is the capital of Denmark".

If in addition "the summit is in Oslo", you can't substitute "Oslo = the capital of Norway" into Bel(B, Cap(O, D)). It might be true that (i) Bush believes the summit is in Oslo, and (ii) Bush believes that Oslo is in Denmark, but not (iii) Bush believes that the capital of Norway is in Denmark.

Equality is not the only thing whose truth value fails to be preserved across intension. Boolean algebra can also fail. This explains an apparent paradox of infallibility versus humility. If you write a book, carefully, you don't know of any spelling mistakes (or typos) in it. If you look and don't find any, you are usually humble enough to suppose that there could well be some there and you have just missed them. You don't believe that the book is entirely free from error. It's just that you don't know of any errors in it.

Consider all the words in the book, W(1), ... , W(n). For each W(i) you believe it is correct. Symbolize this as
So we have the chain
Bel(Corr(W(1))) & ... & Bel(Corr(W(n))).
This sounds, when spoken out loud in English, that you're claiming perfection. But a claim of perfection is actually a different construct, namely
Bel( Corr(W(1)) & ... & Corr(W(n)) ).
You can't play with the bracketing while preserving truth.