Is this an adjective phrase? Is 'when her husband mentions an invitation to a dinner party' an adjective phrase? I think 'to a dinner party' is a prep phrase modifying invitation right?
Your first phrase -- "'when her husband mentions an invitation to a dinner party" -- is not an adjective phrase in its function. In its function, it's an adverb phrase. Adjective phrases (whether just one word or a long series of words) modify nouns or pronouns and answer questions such as "which?" or "what kind of....?" Adverb phrases modify verbs (and a lot of other things, just not nouns) and answer questions such as "when?", "where?", "how?", "why?", or "to what extent?" Some grammarians classify adverb phrases based on which questions they answer, giving us adverbs of time or condition ("when?") or place or manner or reason or extent.
You're right about the second phrase -- "to a dinner party." It's a prepositional phrase and modifies "invitation."
Prepositional phrases often work (or function, as you might hear it called) as adverbs. "They went to a dinner party" offers an example. In this sentence, "to a dinner party" modifies "went," tells where, and thus is a prepositional phrase functioning as an adverb.
As a rule, of course, you need to look at the entire sentence to be able to determine if something is an adverb or adjective. Definitions of (and terms for) parts of speech and grammatical functions also vary a little from source to source; you need to look carefully at the defintions and terms that you're working with.
yayme99 asked: "because 'to a dinner party' is a prep phrase modifying invitation and invitation is a noun wouldn't it be an adjective phrase?"
Yes. It's both an prepositional phrase (in its form) and an adjective phrase (in its function). All phrases have both form and function. Here's my short sample sentence again:
"They went to a dinner party"
In this sentence, the word "they" is both a pronoun (that's its form) and the subject of the sentence (that's its function). As you know, certain grammatical forms have a limited number of functions that they can fill. For example, the subject function can be filled only by nouns, pronouns, and gerunds. (I don't think I'm forgetting anything here. Am I?) (EDIT: I did forget a number of other possibilities! Two other forms that can fill the subject function are that-clauses and wh-clauses. There are probably at least a few more, too.)
Thus, in the dependent clause "when her husband mentions an invitation to a dinner party," the phrase "to a dinner party" is a prepositional phrase in form (it has a preposition and an object of the preposition) and an adjective phrase in function (it modifies the noun "invitation").