Anaphoric reference occurs when a word or phrase refers to something mentioned earlier in the discourse. For example:
Michael went to the bank. He was annoyed because it was closed.
He refers to Michael.
it refers to the bank.
Anaphoric reference often makes use of the definite article the, because one of the functions of the definite article is to indicate that something has already been mentioned. For example:
He sat down at the table and took a small box from his pocket. The object felt heavy in his hands. Inside it was the key to his future.
Both the object and it refer back to a small box in the first sentence.
Cataphoric reference occurs when a word or phrase refers to something mentioned later in the discourse.
Although I phone her every week, my mother still complains that I don’t keep in touch often enough.
Her refers to my mother.
The book was there on the table. I’d never read Moby Dick and I didn’t intend to do so now.
The refers to Moby Dick.
Exophoric reference occurs when a word or phrase refers to something outside the discourse.
They’re late again, can you believe it?”
“I know! Well, they’d better get here soon or it’ll get cold.”
They refers to some people outside the discourse known to both speakers.
It also refers to something that both speakers know about (perhaps the dinner).
The use of exophoric reference requires some shared knowledge between two speakers, or between writer and reader(s).